diff options
Diffstat (limited to 'meta/packages/glibc/glibc-2.4/local-stdio-lock.diff')
-rw-r--r-- | meta/packages/glibc/glibc-2.4/local-stdio-lock.diff | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/meta/packages/glibc/glibc-2.4/local-stdio-lock.diff b/meta/packages/glibc/glibc-2.4/local-stdio-lock.diff new file mode 100644 index 0000000000..65cd2fd6b4 --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/local-stdio-lock.diff | |||
@@ -0,0 +1,34 @@ | |||
1 | --- | ||
2 | bits/stdio-lock.h | 17 +++++++++++++---- | ||
3 | 1 file changed, 13 insertions(+), 4 deletions(-) | ||
4 | |||
5 | --- glibc-2.7.orig/bits/stdio-lock.h | ||
6 | +++ glibc-2.7/bits/stdio-lock.h | ||
7 | @@ -45,14 +45,23 @@ __libc_lock_define_recursive (typedef, _ | ||
8 | #define _IO_cleanup_region_end(_doit) \ | ||
9 | __libc_cleanup_region_end (_doit) | ||
10 | |||
11 | #if defined _LIBC && !defined NOT_IN_libc | ||
12 | # define _IO_acquire_lock(_fp) \ | ||
13 | - _IO_cleanup_region_start ((void (*) (void *)) _IO_funlockfile, (_fp)); \ | ||
14 | - _IO_flockfile (_fp) | ||
15 | + { \ | ||
16 | + _IO_FILE *_IO_acquire_lock_file = _fp; \ | ||
17 | + __libc_cleanup_region_start (1, (void (*) (void *)) _IO_acquire_lock_fct, &_IO_acquire_lock_file); \ | ||
18 | + _IO_flockfile (_IO_acquire_lock_file) | ||
19 | + | ||
20 | +# define _IO_acquire_lock_clear_flags2(_fp) \ | ||
21 | + { \ | ||
22 | + _IO_FILE *_IO_acquire_lock_file = _fp; \ | ||
23 | + __libc_cleanup_region_start (1, (void (*) (void *)) _IO_acquire_lock_clear_flags2_fct, &_IO_acquire_lock_file); \ | ||
24 | + _IO_flockfile (_IO_acquire_lock_file) | ||
25 | |||
26 | # define _IO_release_lock(_fp) \ | ||
27 | - _IO_funlockfile (_fp); \ | ||
28 | - _IO_cleanup_region_end (0) | ||
29 | + __libc_cleanup_region_end (1); \ | ||
30 | + } | ||
31 | + | ||
32 | #endif | ||
33 | |||
34 | #endif /* bits/stdio-lock.h */ | ||