mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-29 11:41:21 +03:00
Remove useless more "if" tests before "free".
* include/inline-hashtab.h (htab_delete): Likewise. * libio/freopen.c (freopen): Likewise. * libio/freopen64.c (freopen64): Likewise. * locale/programs/ld-collate.c (collate_read): Likewise. * misc/fstab.c (libc_freeres_fn): Likewise. * posix/glob.c (globfree): Likewise.
This commit is contained in:
10
ChangeLog
10
ChangeLog
@ -1,3 +1,13 @@
|
|||||||
|
2008-05-26 Jim Meyering <meyering@redhat.com>
|
||||||
|
|
||||||
|
Remove useless more "if" tests before "free".
|
||||||
|
* include/inline-hashtab.h (htab_delete): Likewise.
|
||||||
|
* libio/freopen.c (freopen): Likewise.
|
||||||
|
* libio/freopen64.c (freopen64): Likewise.
|
||||||
|
* locale/programs/ld-collate.c (collate_read): Likewise.
|
||||||
|
* misc/fstab.c (libc_freeres_fn): Likewise.
|
||||||
|
* posix/glob.c (globfree): Likewise.
|
||||||
|
|
||||||
2008-05-24 Ulrich Drepper <drepper@redhat.com>
|
2008-05-24 Ulrich Drepper <drepper@redhat.com>
|
||||||
|
|
||||||
* string/Makefile (strop-tests): Add memmem.
|
* string/Makefile (strop-tests): Add memmem.
|
||||||
|
@ -142,8 +142,7 @@ htab_delete (struct hashtab *htab)
|
|||||||
int i;
|
int i;
|
||||||
|
|
||||||
for (i = htab->size - 1; i >= 0; i--)
|
for (i = htab->size - 1; i >= 0; i--)
|
||||||
if (htab->entries[i])
|
free (htab->entries[i]);
|
||||||
free (htab->entries[i]);
|
|
||||||
|
|
||||||
if (htab->free)
|
if (htab->free)
|
||||||
htab->free (htab->entries);
|
htab->free (htab->entries);
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* Copyright (C) 1993,95,96,97,98,2000,2001,2002,2003
|
/* Copyright (C) 1993,95,96,97,98,2000,2001,2002,2003,2008
|
||||||
Free Software Foundation, Inc.
|
Free Software Foundation, Inc.
|
||||||
This file is part of the GNU C Library.
|
This file is part of the GNU C Library.
|
||||||
|
|
||||||
@ -80,8 +80,7 @@ freopen (filename, mode, fp)
|
|||||||
if (fd != -1)
|
if (fd != -1)
|
||||||
{
|
{
|
||||||
__close (fd);
|
__close (fd);
|
||||||
if (filename != NULL)
|
free ((char *) filename);
|
||||||
free ((char *) filename);
|
|
||||||
}
|
}
|
||||||
_IO_release_lock (fp);
|
_IO_release_lock (fp);
|
||||||
return result;
|
return result;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* Copyright (C) 1993,1995,1996,1997,1998,2000,2001,2002, 2003
|
/* Copyright (C) 1993,1995,1996,1997,1998,2000,2001,2002, 2003, 2008
|
||||||
Free Software Foundation, Inc.
|
Free Software Foundation, Inc.
|
||||||
This file is part of the GNU C Library.
|
This file is part of the GNU C Library.
|
||||||
|
|
||||||
@ -64,8 +64,7 @@ freopen64 (filename, mode, fp)
|
|||||||
if (fd != -1)
|
if (fd != -1)
|
||||||
{
|
{
|
||||||
__close (fd);
|
__close (fd);
|
||||||
if (filename != NULL)
|
free ((char *) filename);
|
||||||
free ((char *) filename);
|
|
||||||
}
|
}
|
||||||
_IO_release_lock (fp);
|
_IO_release_lock (fp);
|
||||||
return result;
|
return result;
|
||||||
|
@ -2961,8 +2961,7 @@ collate_read (struct linereader *ldfile, struct localedef_t *result,
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
col_elem_free:
|
col_elem_free:
|
||||||
if (symbol != NULL)
|
free ((char *) symbol);
|
||||||
free ((char *) symbol);
|
|
||||||
free (arg->val.str.startmb);
|
free (arg->val.str.startmb);
|
||||||
free (arg->val.str.startwc);
|
free (arg->val.str.startwc);
|
||||||
}
|
}
|
||||||
@ -3142,8 +3141,7 @@ collate_read (struct linereader *ldfile, struct localedef_t *result,
|
|||||||
arg = lr_token (ldfile, charmap, result, repertoire, verbose);
|
arg = lr_token (ldfile, charmap, result, repertoire, verbose);
|
||||||
if (arg->tok != tok_bsymbol)
|
if (arg->tok != tok_bsymbol)
|
||||||
{
|
{
|
||||||
if (newname != NULL)
|
free ((char *) newname);
|
||||||
free ((char *) newname);
|
|
||||||
goto err_label;
|
goto err_label;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -3157,10 +3155,8 @@ collate_read (struct linereader *ldfile, struct localedef_t *result,
|
|||||||
"LC_COLLATE");
|
"LC_COLLATE");
|
||||||
|
|
||||||
sym_equiv_free:
|
sym_equiv_free:
|
||||||
if (newname != NULL)
|
free ((char *) newname);
|
||||||
free ((char *) newname);
|
free ((char *) symname);
|
||||||
if (symname != NULL)
|
|
||||||
free ((char *) symname);
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (symname == NULL)
|
if (symname == NULL)
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
/* Copyright (C) 1995, 1996, 1997, 1998, 2000 Free Software Foundation, Inc.
|
/* Copyright (C) 1995, 1996, 1997, 1998, 2000, 2008
|
||||||
|
Free Software Foundation, Inc.
|
||||||
This file is part of the GNU C Library.
|
This file is part of the GNU C Library.
|
||||||
|
|
||||||
The GNU C Library is free software; you can redistribute it and/or
|
The GNU C Library is free software; you can redistribute it and/or
|
||||||
@ -185,6 +186,5 @@ libc_freeres_fn (fstab_free)
|
|||||||
char *buffer;
|
char *buffer;
|
||||||
|
|
||||||
buffer = fstab_state.fs_buffer;
|
buffer = fstab_state.fs_buffer;
|
||||||
if (buffer != NULL)
|
free ((void *) buffer);
|
||||||
free ((void *) buffer);
|
|
||||||
}
|
}
|
||||||
|
@ -1,3 +1,25 @@
|
|||||||
|
2008-05-23 Paul Pluzhnikov <ppluzhnikov@google.com>
|
||||||
|
|
||||||
|
* sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Add
|
||||||
|
cfi directives.
|
||||||
|
* sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
|
||||||
|
* sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
|
||||||
|
* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
|
||||||
|
* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
|
||||||
|
* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
|
||||||
|
* sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
|
||||||
|
|
||||||
|
2008-05-22 Paul Pluzhnikov <ppluzhnikov@google.com>
|
||||||
|
|
||||||
|
* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S: Add
|
||||||
|
cfi directives.
|
||||||
|
* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
|
||||||
|
Likewise.
|
||||||
|
* sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
|
||||||
|
Likewise.
|
||||||
|
* sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
|
||||||
|
Likewise.
|
||||||
|
|
||||||
2008-05-26 Ulrich Drepper <drepper@redhat.com>
|
2008-05-26 Ulrich Drepper <drepper@redhat.com>
|
||||||
|
|
||||||
* tst-typesizes.c: Explicitly check __SIZEOF_PTHREAD_* constants.
|
* tst-typesizes.c: Explicitly check __SIZEOF_PTHREAD_* constants.
|
||||||
|
@ -27,7 +27,10 @@
|
|||||||
.type pthread_barrier_wait,@function
|
.type pthread_barrier_wait,@function
|
||||||
.align 16
|
.align 16
|
||||||
pthread_barrier_wait:
|
pthread_barrier_wait:
|
||||||
|
cfi_startproc
|
||||||
pushl %ebx
|
pushl %ebx
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
|
|
||||||
movl 8(%esp), %ebx
|
movl 8(%esp), %ebx
|
||||||
|
|
||||||
@ -45,6 +48,8 @@ pthread_barrier_wait:
|
|||||||
|
|
||||||
/* There are more threads to come. */
|
/* There are more threads to come. */
|
||||||
pushl %esi
|
pushl %esi
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%esi, -12)
|
||||||
|
|
||||||
#if CURR_EVENT == 0
|
#if CURR_EVENT == 0
|
||||||
movl (%ebx), %edx
|
movl (%ebx), %edx
|
||||||
@ -101,9 +106,16 @@ pthread_barrier_wait:
|
|||||||
10: movl %esi, %eax /* != PTHREAD_BARRIER_SERIAL_THREAD */
|
10: movl %esi, %eax /* != PTHREAD_BARRIER_SERIAL_THREAD */
|
||||||
|
|
||||||
popl %esi
|
popl %esi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%esi)
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
|
|
||||||
/* The necessary number of threads arrived. */
|
/* The necessary number of threads arrived. */
|
||||||
3:
|
3:
|
||||||
#if CURR_EVENT == 0
|
#if CURR_EVENT == 0
|
||||||
@ -140,8 +152,12 @@ pthread_barrier_wait:
|
|||||||
5: orl $-1, %eax /* == PTHREAD_BARRIER_SERIAL_THREAD */
|
5: orl $-1, %eax /* == PTHREAD_BARRIER_SERIAL_THREAD */
|
||||||
|
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
1: movl PRIVATE(%ebx), %ecx
|
1: movl PRIVATE(%ebx), %ecx
|
||||||
leal MUTEX(%ebx), %edx
|
leal MUTEX(%ebx), %edx
|
||||||
xorl $LLL_SHARED, %ecx
|
xorl $LLL_SHARED, %ecx
|
||||||
@ -154,6 +170,8 @@ pthread_barrier_wait:
|
|||||||
call __lll_unlock_wake
|
call __lll_unlock_wake
|
||||||
jmp 5b
|
jmp 5b
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%esi, -12)
|
||||||
6: movl PRIVATE(%ebx), %ecx
|
6: movl PRIVATE(%ebx), %ecx
|
||||||
leal MUTEX(%ebx), %eax
|
leal MUTEX(%ebx), %eax
|
||||||
xorl $LLL_SHARED, %ecx
|
xorl $LLL_SHARED, %ecx
|
||||||
@ -165,4 +183,5 @@ pthread_barrier_wait:
|
|||||||
xorl $LLL_SHARED, %ecx
|
xorl $LLL_SHARED, %ecx
|
||||||
call __lll_unlock_wake
|
call __lll_unlock_wake
|
||||||
jmp 10b
|
jmp 10b
|
||||||
|
cfi_endproc
|
||||||
.size pthread_barrier_wait,.-pthread_barrier_wait
|
.size pthread_barrier_wait,.-pthread_barrier_wait
|
||||||
|
@ -32,11 +32,19 @@
|
|||||||
.type __pthread_cond_broadcast, @function
|
.type __pthread_cond_broadcast, @function
|
||||||
.align 16
|
.align 16
|
||||||
__pthread_cond_broadcast:
|
__pthread_cond_broadcast:
|
||||||
|
cfi_startproc
|
||||||
pushl %ebx
|
pushl %ebx
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %esi
|
pushl %esi
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %edi
|
pushl %edi
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %ebp
|
pushl %ebp
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
|
cfi_offset(%esi, -12)
|
||||||
|
cfi_offset(%edi, -16)
|
||||||
|
cfi_offset(%ebp, -20)
|
||||||
|
|
||||||
movl 20(%esp), %ebx
|
movl 20(%esp), %ebx
|
||||||
|
|
||||||
@ -114,11 +122,24 @@ __pthread_cond_broadcast:
|
|||||||
|
|
||||||
10: xorl %eax, %eax
|
10: xorl %eax, %eax
|
||||||
popl %ebp
|
popl %ebp
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebp)
|
||||||
popl %edi
|
popl %edi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%edi)
|
||||||
popl %esi
|
popl %esi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%esi)
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(16)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
|
cfi_offset(%esi, -12)
|
||||||
|
cfi_offset(%edi, -16)
|
||||||
|
cfi_offset(%ebp, -20)
|
||||||
.align 16
|
.align 16
|
||||||
/* Unlock. */
|
/* Unlock. */
|
||||||
4: LOCK
|
4: LOCK
|
||||||
@ -127,11 +148,24 @@ __pthread_cond_broadcast:
|
|||||||
|
|
||||||
6: xorl %eax, %eax
|
6: xorl %eax, %eax
|
||||||
popl %ebp
|
popl %ebp
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebp)
|
||||||
popl %edi
|
popl %edi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%edi)
|
||||||
popl %esi
|
popl %esi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%esi)
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(16)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
|
cfi_offset(%esi, -12)
|
||||||
|
cfi_offset(%edi, -16)
|
||||||
|
cfi_offset(%ebp, -20)
|
||||||
/* Initial locking failed. */
|
/* Initial locking failed. */
|
||||||
1:
|
1:
|
||||||
#if cond_lock == 0
|
#if cond_lock == 0
|
||||||
@ -199,6 +233,7 @@ __pthread_cond_broadcast:
|
|||||||
movl $SYS_futex, %eax
|
movl $SYS_futex, %eax
|
||||||
ENTER_KERNEL
|
ENTER_KERNEL
|
||||||
jmp 10b
|
jmp 10b
|
||||||
|
cfi_endproc
|
||||||
.size __pthread_cond_broadcast, .-__pthread_cond_broadcast
|
.size __pthread_cond_broadcast, .-__pthread_cond_broadcast
|
||||||
versioned_symbol (libpthread, __pthread_cond_broadcast, pthread_cond_broadcast,
|
versioned_symbol (libpthread, __pthread_cond_broadcast, pthread_cond_broadcast,
|
||||||
GLIBC_2_3_2)
|
GLIBC_2_3_2)
|
||||||
|
@ -33,8 +33,13 @@
|
|||||||
.align 16
|
.align 16
|
||||||
__pthread_cond_signal:
|
__pthread_cond_signal:
|
||||||
|
|
||||||
|
cfi_startproc
|
||||||
pushl %ebx
|
pushl %ebx
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %edi
|
pushl %edi
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
|
cfi_offset(%edi, -12)
|
||||||
|
|
||||||
movl 12(%esp), %edi
|
movl 12(%esp), %edi
|
||||||
|
|
||||||
@ -69,7 +74,12 @@ __pthread_cond_signal:
|
|||||||
|
|
||||||
/* Wake up one thread. */
|
/* Wake up one thread. */
|
||||||
pushl %esi
|
pushl %esi
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %ebp
|
pushl %ebp
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%esi, -16)
|
||||||
|
cfi_offset(%ebp, -20)
|
||||||
|
|
||||||
#if FUTEX_PRIVATE_FLAG > 255
|
#if FUTEX_PRIVATE_FLAG > 255
|
||||||
xorl %ecx, %ecx
|
xorl %ecx, %ecx
|
||||||
#endif
|
#endif
|
||||||
@ -91,7 +101,11 @@ __pthread_cond_signal:
|
|||||||
ENTER_KERNEL */
|
ENTER_KERNEL */
|
||||||
int $0x80
|
int $0x80
|
||||||
popl %ebp
|
popl %ebp
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebp)
|
||||||
popl %esi
|
popl %esi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%esi)
|
||||||
|
|
||||||
/* For any kind of error, we try again with WAKE.
|
/* For any kind of error, we try again with WAKE.
|
||||||
The general test also covers running on old kernels. */
|
The general test also covers running on old kernels. */
|
||||||
@ -100,9 +114,17 @@ __pthread_cond_signal:
|
|||||||
|
|
||||||
6: xorl %eax, %eax
|
6: xorl %eax, %eax
|
||||||
popl %edi
|
popl %edi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%edi)
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(8)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
|
cfi_offset(%edi, -12)
|
||||||
|
|
||||||
7: /* %ecx should be either FUTEX_WAKE_OP or
|
7: /* %ecx should be either FUTEX_WAKE_OP or
|
||||||
FUTEX_WAKE_OP|FUTEX_PRIVATE_FLAG from the previous syscall. */
|
FUTEX_WAKE_OP|FUTEX_PRIVATE_FLAG from the previous syscall. */
|
||||||
xorl $(FUTEX_WAKE ^ FUTEX_WAKE_OP), %ecx
|
xorl $(FUTEX_WAKE ^ FUTEX_WAKE_OP), %ecx
|
||||||
@ -152,6 +174,7 @@ __pthread_cond_signal:
|
|||||||
call __lll_lock_wait
|
call __lll_lock_wait
|
||||||
jmp 2b
|
jmp 2b
|
||||||
|
|
||||||
|
cfi_endproc
|
||||||
.size __pthread_cond_signal, .-__pthread_cond_signal
|
.size __pthread_cond_signal, .-__pthread_cond_signal
|
||||||
versioned_symbol (libpthread, __pthread_cond_signal, pthread_cond_signal,
|
versioned_symbol (libpthread, __pthread_cond_signal, pthread_cond_signal,
|
||||||
GLIBC_2_3_2)
|
GLIBC_2_3_2)
|
||||||
|
@ -30,8 +30,13 @@
|
|||||||
.type __pthread_rwlock_rdlock,@function
|
.type __pthread_rwlock_rdlock,@function
|
||||||
.align 16
|
.align 16
|
||||||
__pthread_rwlock_rdlock:
|
__pthread_rwlock_rdlock:
|
||||||
|
cfi_startproc
|
||||||
pushl %esi
|
pushl %esi
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %ebx
|
pushl %ebx
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%esi, -8)
|
||||||
|
cfi_offset(%ebx, -12)
|
||||||
|
|
||||||
xorl %esi, %esi
|
xorl %esi, %esi
|
||||||
movl 12(%esp), %ebx
|
movl 12(%esp), %ebx
|
||||||
@ -113,9 +118,16 @@ __pthread_rwlock_rdlock:
|
|||||||
|
|
||||||
movl %edx, %eax
|
movl %edx, %eax
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
popl %esi
|
popl %esi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%esi)
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(8)
|
||||||
|
cfi_offset(%esi, -8)
|
||||||
|
cfi_offset(%ebx, -12)
|
||||||
1:
|
1:
|
||||||
#if MUTEX == 0
|
#if MUTEX == 0
|
||||||
movl %ebx, %edx
|
movl %ebx, %edx
|
||||||
@ -171,6 +183,7 @@ __pthread_rwlock_rdlock:
|
|||||||
movzbl PSHARED(%ebx), %ecx
|
movzbl PSHARED(%ebx), %ecx
|
||||||
call __lll_lock_wait
|
call __lll_lock_wait
|
||||||
jmp 13b
|
jmp 13b
|
||||||
|
cfi_endproc
|
||||||
.size __pthread_rwlock_rdlock,.-__pthread_rwlock_rdlock
|
.size __pthread_rwlock_rdlock,.-__pthread_rwlock_rdlock
|
||||||
|
|
||||||
.globl pthread_rwlock_rdlock
|
.globl pthread_rwlock_rdlock
|
||||||
|
@ -30,11 +30,21 @@
|
|||||||
.type pthread_rwlock_timedrdlock,@function
|
.type pthread_rwlock_timedrdlock,@function
|
||||||
.align 16
|
.align 16
|
||||||
pthread_rwlock_timedrdlock:
|
pthread_rwlock_timedrdlock:
|
||||||
|
cfi_startproc
|
||||||
pushl %esi
|
pushl %esi
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %edi
|
pushl %edi
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %ebx
|
pushl %ebx
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %ebp
|
pushl %ebp
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%esi, -8)
|
||||||
|
cfi_offset(%edi, -12)
|
||||||
|
cfi_offset(%ebx, -16)
|
||||||
|
cfi_offset(%ebp, -20)
|
||||||
subl $8, %esp
|
subl $8, %esp
|
||||||
|
cfi_adjust_cfa_offset(8)
|
||||||
|
|
||||||
movl 28(%esp), %ebp
|
movl 28(%esp), %ebp
|
||||||
movl 32(%esp), %edi
|
movl 32(%esp), %edi
|
||||||
@ -150,12 +160,26 @@ pthread_rwlock_timedrdlock:
|
|||||||
7: movl %edx, %eax
|
7: movl %edx, %eax
|
||||||
|
|
||||||
addl $8, %esp
|
addl $8, %esp
|
||||||
|
cfi_adjust_cfa_offset(-8)
|
||||||
popl %ebp
|
popl %ebp
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebp)
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
popl %edi
|
popl %edi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%edi)
|
||||||
popl %esi
|
popl %esi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%esi)
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(24)
|
||||||
|
cfi_offset(%esi, -8)
|
||||||
|
cfi_offset(%edi, -12)
|
||||||
|
cfi_offset(%ebx, -16)
|
||||||
|
cfi_offset(%ebp, -20)
|
||||||
1:
|
1:
|
||||||
#if MUTEX == 0
|
#if MUTEX == 0
|
||||||
movl %ebp, %edx
|
movl %ebp, %edx
|
||||||
@ -216,4 +240,5 @@ pthread_rwlock_timedrdlock:
|
|||||||
|
|
||||||
19: movl $EINVAL, %edx
|
19: movl $EINVAL, %edx
|
||||||
jmp 9b
|
jmp 9b
|
||||||
|
cfi_endproc
|
||||||
.size pthread_rwlock_timedrdlock,.-pthread_rwlock_timedrdlock
|
.size pthread_rwlock_timedrdlock,.-pthread_rwlock_timedrdlock
|
||||||
|
@ -30,11 +30,21 @@
|
|||||||
.type pthread_rwlock_timedwrlock,@function
|
.type pthread_rwlock_timedwrlock,@function
|
||||||
.align 16
|
.align 16
|
||||||
pthread_rwlock_timedwrlock:
|
pthread_rwlock_timedwrlock:
|
||||||
|
cfi_startproc
|
||||||
pushl %esi
|
pushl %esi
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %edi
|
pushl %edi
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %ebx
|
pushl %ebx
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %ebp
|
pushl %ebp
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%esi, -8)
|
||||||
|
cfi_offset(%edi, -12)
|
||||||
|
cfi_offset(%ebx, -16)
|
||||||
|
cfi_offset(%ebp, -20)
|
||||||
subl $8, %esp
|
subl $8, %esp
|
||||||
|
cfi_adjust_cfa_offset(8)
|
||||||
|
|
||||||
movl 28(%esp), %ebp
|
movl 28(%esp), %ebp
|
||||||
movl 32(%esp), %edi
|
movl 32(%esp), %edi
|
||||||
@ -148,12 +158,26 @@ pthread_rwlock_timedwrlock:
|
|||||||
7: movl %edx, %eax
|
7: movl %edx, %eax
|
||||||
|
|
||||||
addl $8, %esp
|
addl $8, %esp
|
||||||
|
cfi_adjust_cfa_offset(-8)
|
||||||
popl %ebp
|
popl %ebp
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebp)
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
popl %edi
|
popl %edi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%edi)
|
||||||
popl %esi
|
popl %esi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%esi)
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(24)
|
||||||
|
cfi_offset(%esi, -8)
|
||||||
|
cfi_offset(%edi, -12)
|
||||||
|
cfi_offset(%ebx, -16)
|
||||||
|
cfi_offset(%ebp, -20)
|
||||||
1:
|
1:
|
||||||
#if MUTEX == 0
|
#if MUTEX == 0
|
||||||
movl %ebp, %edx
|
movl %ebp, %edx
|
||||||
@ -209,4 +233,5 @@ pthread_rwlock_timedwrlock:
|
|||||||
|
|
||||||
19: movl $EINVAL, %edx
|
19: movl $EINVAL, %edx
|
||||||
jmp 9b
|
jmp 9b
|
||||||
|
cfi_endproc
|
||||||
.size pthread_rwlock_timedwrlock,.-pthread_rwlock_timedwrlock
|
.size pthread_rwlock_timedwrlock,.-pthread_rwlock_timedwrlock
|
||||||
|
@ -29,8 +29,13 @@
|
|||||||
.type __pthread_rwlock_unlock,@function
|
.type __pthread_rwlock_unlock,@function
|
||||||
.align 16
|
.align 16
|
||||||
__pthread_rwlock_unlock:
|
__pthread_rwlock_unlock:
|
||||||
|
cfi_startproc
|
||||||
pushl %ebx
|
pushl %ebx
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %edi
|
pushl %edi
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
|
cfi_offset(%edi, -12)
|
||||||
|
|
||||||
movl 12(%esp), %edi
|
movl 12(%esp), %edi
|
||||||
|
|
||||||
@ -87,9 +92,16 @@ __pthread_rwlock_unlock:
|
|||||||
|
|
||||||
xorl %eax, %eax
|
xorl %eax, %eax
|
||||||
popl %edi
|
popl %edi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%edi)
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(8)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
|
cfi_offset(%edi, -12)
|
||||||
.align 16
|
.align 16
|
||||||
6: LOCK
|
6: LOCK
|
||||||
#if MUTEX == 0
|
#if MUTEX == 0
|
||||||
@ -133,7 +145,7 @@ __pthread_rwlock_unlock:
|
|||||||
movzbl PSHARED(%edi), %ecx
|
movzbl PSHARED(%edi), %ecx
|
||||||
call __lll_unlock_wake
|
call __lll_unlock_wake
|
||||||
jmp 8b
|
jmp 8b
|
||||||
|
cfi_endproc
|
||||||
.size __pthread_rwlock_unlock,.-__pthread_rwlock_unlock
|
.size __pthread_rwlock_unlock,.-__pthread_rwlock_unlock
|
||||||
|
|
||||||
.globl pthread_rwlock_unlock
|
.globl pthread_rwlock_unlock
|
||||||
|
@ -30,8 +30,13 @@
|
|||||||
.type __pthread_rwlock_wrlock,@function
|
.type __pthread_rwlock_wrlock,@function
|
||||||
.align 16
|
.align 16
|
||||||
__pthread_rwlock_wrlock:
|
__pthread_rwlock_wrlock:
|
||||||
|
cfi_startproc
|
||||||
pushl %esi
|
pushl %esi
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
pushl %ebx
|
pushl %ebx
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%esi, -8)
|
||||||
|
cfi_offset(%ebx, -12)
|
||||||
|
|
||||||
xorl %esi, %esi
|
xorl %esi, %esi
|
||||||
movl 12(%esp), %ebx
|
movl 12(%esp), %ebx
|
||||||
@ -111,9 +116,16 @@ __pthread_rwlock_wrlock:
|
|||||||
|
|
||||||
movl %edx, %eax
|
movl %edx, %eax
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
popl %esi
|
popl %esi
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%esi)
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(8)
|
||||||
|
cfi_offset(%esi, -8)
|
||||||
|
cfi_offset(%ebx, -12)
|
||||||
1:
|
1:
|
||||||
#if MUTEX == 0
|
#if MUTEX == 0
|
||||||
movl %ebx, %edx
|
movl %ebx, %edx
|
||||||
@ -162,6 +174,7 @@ __pthread_rwlock_wrlock:
|
|||||||
movzbl PSHARED(%ebx), %ecx
|
movzbl PSHARED(%ebx), %ecx
|
||||||
call __lll_lock_wait
|
call __lll_lock_wait
|
||||||
jmp 13b
|
jmp 13b
|
||||||
|
cfi_endproc
|
||||||
.size __pthread_rwlock_wrlock,.-__pthread_rwlock_wrlock
|
.size __pthread_rwlock_wrlock,.-__pthread_rwlock_wrlock
|
||||||
|
|
||||||
.globl pthread_rwlock_wrlock
|
.globl pthread_rwlock_wrlock
|
||||||
|
@ -30,7 +30,10 @@
|
|||||||
.type __new_sem_post,@function
|
.type __new_sem_post,@function
|
||||||
.align 16
|
.align 16
|
||||||
__new_sem_post:
|
__new_sem_post:
|
||||||
|
cfi_startproc
|
||||||
pushl %ebx
|
pushl %ebx
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
|
|
||||||
movl 8(%esp), %ebx
|
movl 8(%esp), %ebx
|
||||||
|
|
||||||
@ -64,8 +67,12 @@ __new_sem_post:
|
|||||||
|
|
||||||
2: xorl %eax, %eax
|
2: xorl %eax, %eax
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
1:
|
1:
|
||||||
#ifdef PIC
|
#ifdef PIC
|
||||||
call __i686.get_pc_thunk.bx
|
call __i686.get_pc_thunk.bx
|
||||||
@ -116,14 +123,20 @@ __new_sem_post:
|
|||||||
|
|
||||||
orl $-1, %eax
|
orl $-1, %eax
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
ret
|
ret
|
||||||
|
cfi_endproc
|
||||||
.size __new_sem_post,.-__new_sem_post
|
.size __new_sem_post,.-__new_sem_post
|
||||||
versioned_symbol(libpthread, __new_sem_post, sem_post, GLIBC_2_1)
|
versioned_symbol(libpthread, __new_sem_post, sem_post, GLIBC_2_1)
|
||||||
#if SHLIB_COMPAT(libpthread, GLIBC_2_0, GLIBC_2_1)
|
#if SHLIB_COMPAT(libpthread, GLIBC_2_0, GLIBC_2_1)
|
||||||
.global __old_sem_post
|
.global __old_sem_post
|
||||||
.type __old_sem_post,@function
|
.type __old_sem_post,@function
|
||||||
__old_sem_post:
|
__old_sem_post:
|
||||||
|
cfi_startproc
|
||||||
pushl %ebx
|
pushl %ebx
|
||||||
|
cfi_adjust_cfa_offset(4)
|
||||||
|
cfi_offset(%ebx, -8)
|
||||||
|
|
||||||
movl 8(%esp), %ebx
|
movl 8(%esp), %ebx
|
||||||
LOCK
|
LOCK
|
||||||
@ -139,7 +152,10 @@ __old_sem_post:
|
|||||||
|
|
||||||
xorl %eax, %eax
|
xorl %eax, %eax
|
||||||
popl %ebx
|
popl %ebx
|
||||||
|
cfi_adjust_cfa_offset(-4)
|
||||||
|
cfi_restore(%ebx)
|
||||||
ret
|
ret
|
||||||
|
cfi_endproc
|
||||||
.size __old_sem_post,.-__old_sem_post
|
.size __old_sem_post,.-__old_sem_post
|
||||||
compat_symbol(libpthread, __old_sem_post, sem_post, GLIBC_2_0)
|
compat_symbol(libpthread, __old_sem_post, sem_post, GLIBC_2_0)
|
||||||
#endif
|
#endif
|
||||||
|
@ -33,10 +33,19 @@
|
|||||||
.type pthread_rwlock_timedrdlock,@function
|
.type pthread_rwlock_timedrdlock,@function
|
||||||
.align 16
|
.align 16
|
||||||
pthread_rwlock_timedrdlock:
|
pthread_rwlock_timedrdlock:
|
||||||
|
cfi_startproc
|
||||||
pushq %r12
|
pushq %r12
|
||||||
|
cfi_adjust_cfa_offset(8)
|
||||||
pushq %r13
|
pushq %r13
|
||||||
|
cfi_adjust_cfa_offset(8)
|
||||||
pushq %r14
|
pushq %r14
|
||||||
|
cfi_adjust_cfa_offset(8)
|
||||||
|
cfi_offset(%r12, -16)
|
||||||
|
cfi_offset(%r13, -24)
|
||||||
|
cfi_offset(%r14, -32)
|
||||||
|
|
||||||
subq $16, %rsp
|
subq $16, %rsp
|
||||||
|
cfi_adjust_cfa_offset(16)
|
||||||
|
|
||||||
movq %rdi, %r12
|
movq %rdi, %r12
|
||||||
movq %rsi, %r13
|
movq %rsi, %r13
|
||||||
@ -155,11 +164,22 @@ pthread_rwlock_timedrdlock:
|
|||||||
7: movq %rdx, %rax
|
7: movq %rdx, %rax
|
||||||
|
|
||||||
addq $16, %rsp
|
addq $16, %rsp
|
||||||
|
cfi_adjust_cfa_offset(-16)
|
||||||
popq %r14
|
popq %r14
|
||||||
|
cfi_adjust_cfa_offset(-8)
|
||||||
|
cfi_restore(%r14)
|
||||||
popq %r13
|
popq %r13
|
||||||
|
cfi_adjust_cfa_offset(-8)
|
||||||
|
cfi_restore(%r13)
|
||||||
popq %r12
|
popq %r12
|
||||||
|
cfi_adjust_cfa_offset(-8)
|
||||||
|
cfi_restore(%r12)
|
||||||
retq
|
retq
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(40)
|
||||||
|
cfi_offset(%r12, -16)
|
||||||
|
cfi_offset(%r13, -24)
|
||||||
|
cfi_offset(%r14, -32)
|
||||||
1: movl PSHARED(%rdi), %esi
|
1: movl PSHARED(%rdi), %esi
|
||||||
#if MUTEX != 0
|
#if MUTEX != 0
|
||||||
addq $MUTEX, %rdi
|
addq $MUTEX, %rdi
|
||||||
@ -214,4 +234,5 @@ pthread_rwlock_timedrdlock:
|
|||||||
|
|
||||||
19: movl $EINVAL, %edx
|
19: movl $EINVAL, %edx
|
||||||
jmp 9b
|
jmp 9b
|
||||||
|
cfi_endproc
|
||||||
.size pthread_rwlock_timedrdlock,.-pthread_rwlock_timedrdlock
|
.size pthread_rwlock_timedrdlock,.-pthread_rwlock_timedrdlock
|
||||||
|
@ -33,10 +33,19 @@
|
|||||||
.type pthread_rwlock_timedwrlock,@function
|
.type pthread_rwlock_timedwrlock,@function
|
||||||
.align 16
|
.align 16
|
||||||
pthread_rwlock_timedwrlock:
|
pthread_rwlock_timedwrlock:
|
||||||
|
cfi_startproc
|
||||||
pushq %r12
|
pushq %r12
|
||||||
|
cfi_adjust_cfa_offset(8)
|
||||||
pushq %r13
|
pushq %r13
|
||||||
|
cfi_adjust_cfa_offset(8)
|
||||||
pushq %r14
|
pushq %r14
|
||||||
|
cfi_adjust_cfa_offset(8)
|
||||||
|
cfi_offset(%r12, -16)
|
||||||
|
cfi_offset(%r13, -24)
|
||||||
|
cfi_offset(%r14, -32)
|
||||||
|
|
||||||
subq $16, %rsp
|
subq $16, %rsp
|
||||||
|
cfi_adjust_cfa_offset(16)
|
||||||
|
|
||||||
movq %rdi, %r12
|
movq %rdi, %r12
|
||||||
movq %rsi, %r13
|
movq %rsi, %r13
|
||||||
@ -152,11 +161,22 @@ pthread_rwlock_timedwrlock:
|
|||||||
7: movq %rdx, %rax
|
7: movq %rdx, %rax
|
||||||
|
|
||||||
addq $16, %rsp
|
addq $16, %rsp
|
||||||
|
cfi_adjust_cfa_offset(-16)
|
||||||
popq %r14
|
popq %r14
|
||||||
|
cfi_adjust_cfa_offset(-8)
|
||||||
|
cfi_restore(%r14)
|
||||||
popq %r13
|
popq %r13
|
||||||
|
cfi_adjust_cfa_offset(-8)
|
||||||
|
cfi_restore(%r13)
|
||||||
popq %r12
|
popq %r12
|
||||||
|
cfi_adjust_cfa_offset(-8)
|
||||||
|
cfi_restore(%r12)
|
||||||
retq
|
retq
|
||||||
|
|
||||||
|
cfi_adjust_cfa_offset(40)
|
||||||
|
cfi_offset(%r12, -16)
|
||||||
|
cfi_offset(%r13, -24)
|
||||||
|
cfi_offset(%r14, -32)
|
||||||
1: movl PSHARED(%rdi), %esi
|
1: movl PSHARED(%rdi), %esi
|
||||||
#if MUTEX != 0
|
#if MUTEX != 0
|
||||||
addq $MUTEX, %rdi
|
addq $MUTEX, %rdi
|
||||||
@ -206,4 +226,5 @@ pthread_rwlock_timedwrlock:
|
|||||||
|
|
||||||
19: movl $EINVAL, %edx
|
19: movl $EINVAL, %edx
|
||||||
jmp 9b
|
jmp 9b
|
||||||
|
cfi_endproc
|
||||||
.size pthread_rwlock_timedwrlock,.-pthread_rwlock_timedwrlock
|
.size pthread_rwlock_timedwrlock,.-pthread_rwlock_timedwrlock
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* Copyright (C) 1991-2002, 2003, 2004, 2005, 2006, 2007
|
/* Copyright (C) 1991-2002, 2003, 2004, 2005, 2006, 2007, 2008
|
||||||
Free Software Foundation, Inc.
|
Free Software Foundation, Inc.
|
||||||
This file is part of the GNU C Library.
|
This file is part of the GNU C Library.
|
||||||
|
|
||||||
@ -1075,8 +1075,7 @@ globfree (pglob)
|
|||||||
{
|
{
|
||||||
size_t i;
|
size_t i;
|
||||||
for (i = 0; i < pglob->gl_pathc; ++i)
|
for (i = 0; i < pglob->gl_pathc; ++i)
|
||||||
if (pglob->gl_pathv[pglob->gl_offs + i] != NULL)
|
free (pglob->gl_pathv[pglob->gl_offs + i]);
|
||||||
free (pglob->gl_pathv[pglob->gl_offs + i]);
|
|
||||||
free (pglob->gl_pathv);
|
free (pglob->gl_pathv);
|
||||||
pglob->gl_pathv = NULL;
|
pglob->gl_pathv = NULL;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user