Skip to content

Commit

Permalink
filesystems/ntfs2btrfs: unbreak the port's build on recent -CURRENT
Browse files Browse the repository at this point in the history
The base template for std::char_traits<> has been removed in LLVM 19;
specializations are only provided for char, wchar_t, char8_t, char16_t,
and char32_t.   Use appropriate type and constify the first argument
as requested by the compiler (char8_t is from C++20, but this matches
already requested CMAKE_CXX_STANDARD).

Nagged by:	pkg-fallout
  • Loading branch information
Alexey Dokuchaev authored and Alexey Dokuchaev committed Dec 22, 2024
1 parent 680b86d commit ded5036
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions filesystems/ntfs2btrfs/files/patch-src_rollback.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
--- src/rollback.cpp.orig 2023-05-01 20:59:36 UTC
+++ src/rollback.cpp
@@ -309,7 +309,7 @@ void btrfs::read_chunks() {

auto& ci = *(CHUNK_ITEM*)(ptr + sizeof(key));

- basic_string_view<uint8_t> chunk_item{ptr + sizeof(key), sizeof(ci) + (ci.num_stripes * sizeof(CHUNK_ITEM_STRIPE))};
+ basic_string_view<char8_t> chunk_item{reinterpret_cast<const char8_t*>(ptr) + sizeof(key), sizeof(ci) + (ci.num_stripes * sizeof(CHUNK_ITEM_STRIPE))};

chunks.emplace(key.offset, buffer_t{chunk_item.data(), chunk_item.data() + chunk_item.size()});

0 comments on commit ded5036

Please sign in to comment.