0
0
Fork 0
mirror of https://github.com/NixOS/nixpkgs.git synced 2025-07-14 06:00:33 +03:00

testdisk: fix gcc-14 build

fix incompatible pointer type by updating a function definition
ntfs_device_testdisk_io_ioctl to take an unsigned long rather than an
int. The function implementation is empty and just returns error so the
updated argument type has no effect.
This commit is contained in:
Reno Dakota 2024-12-20 01:28:20 +00:00
parent 2312c397a8
commit 03d440cc8e
No known key found for this signature in database
2 changed files with 19 additions and 0 deletions

View file

@ -33,6 +33,10 @@ assert enableQt -> qwt != null;
sha256 = "1zlh44w67py416hkvw6nrfmjickc2d43v51vcli5p374d5sw84ql";
};
patches = [
./gcc-14-fixes.diff
];
postPatch = ''
substituteInPlace linux/qphotorec.desktop \
--replace "/usr" "$out"

View file

@ -0,0 +1,15 @@
diff --git a/src/ntfs_io.c b/src/ntfs_io.c
index 7f57edd..4b718bb 100644
--- a/src/ntfs_io.c
+++ b/src/ntfs_io.c
@@ -154,8 +154,8 @@ static int ntfs_device_testdisk_io_stat(struct ntfs_device *dev, struct stat *bu
return -1;
}
-static int ntfs_device_testdisk_io_ioctl(struct ntfs_device *dev, int request,
- void *argp)
+static int ntfs_device_testdisk_io_ioctl(struct ntfs_device *dev,
+ unsigned long request, void *argp)
{
log_warning( "ntfs_device_testdisk_io_ioctl() unimplemented\n");
#ifdef ENOTSUP