gentoo-ebuilds/sci-mathematics/msieve/files/msieve-1.53-gzfile.patch
NHOrus 3086ccda6f
sci-mathematics/msieve: Port to C23
Closes: https://bugs.gentoo.org/920312
Signed-off-by: NHOrus <jy6x2b32pie9@yahoo.com>
Closes: https://github.com/gentoo/gentoo/pull/41303
Signed-off-by: Sam James <sam@gentoo.org>
2025-04-12 21:57:20 +01:00

25 lines
566 B
Diff

Don't double-pointer and then assign from single-pointer
Fixes compilation with GCC-15
https://bugs.gentoo.org/920312
--- a/common/savefile.c
+++ b/common/savefile.c
@@ -152,7 +152,7 @@
fclose(fp);
}
if (s->is_a_FILE) {
- s->fp = (gzFile *)fopen(s->name, "a");
+ s->fp = (gzFile)fopen(s->name, "a");
} else {
s->fp = gzopen(s->name, "a");
s->isCompressed = 1;
--- a/include/msieve.h
+++ b/include/msieve.h
@@ -101,7 +101,7 @@
uint32 read_size;
uint32 eof;
#else
- gzFile *fp;
+ gzFile fp;
char isCompressed;
char is_a_FILE;
#endif