glibc/glibc-RHEL-55471-6.patch
Tulio Magno Quites Machado Filho e87166d350 Backport fwrite tests and a fix for BZ 29459
Resolves: RHEL-55471
2025-03-10 14:29:47 -03:00

40 lines
1.1 KiB
Diff

commit cdb0800022110bc68a033944f09e501be5bd72d7
Author: Tulio Magno Quites Machado Filho <tuliom@redhat.com>
Date: Thu Jan 30 15:51:01 2025 -0300
libio: Replace __LP64__ with __WORDSIZE
__LP64__ is a GCC extension and shouldn't be used in an installed
header.
Fixes: 596a61cf6b (libio: Start to return errors when flushing fwrite's buffer [BZ #29459], 2025-01-28)
Reported-by: Florian Weimer <fweimer@redhat.com>
Reviewed-by: Arjun Shankar <arjun@redhat.com>
diff --git a/libio/bits/types/struct_FILE.h b/libio/bits/types/struct_FILE.h
index 7292334a28ad3f79..59f316f8a03d9498 100644
--- a/libio/bits/types/struct_FILE.h
+++ b/libio/bits/types/struct_FILE.h
@@ -32,6 +32,7 @@
#endif
#include <bits/types.h>
+#include <bits/wordsize.h>
struct _IO_FILE;
struct _IO_marker;
@@ -102,11 +103,11 @@ struct _IO_FILE_complete
void *_freeres_buf;
size_t __pad5;
int _mode;
-#ifdef __LP64__
+#if __WORDSIZE == 64
int _unused3;
#endif
__uint64_t _total_written;
-#ifndef __LP64__
+#if __WORDSIZE == 32
int _unused3;
#endif
/* Make sure we don't get into trouble again. */