mirror of
https://sourceware.org/git/glibc.git
synced 2024-11-21 20:40:05 +00:00
30891f35fa
We stopped adding "Contributed by" or similar lines in sources in 2012 in favour of git logs and keeping the Contributors section of the glibc manual up to date. Removing these lines makes the license header a bit more consistent across files and also removes the possibility of error in attribution when license blocks or files are copied across since the contributed-by lines don't actually reflect reality in those cases. Move all "Contributed by" and similar lines (Written by, Test by, etc.) into a new file CONTRIBUTED-BY to retain record of these contributions. These contributors are also mentioned in manual/contrib.texi, so we just maintain this additional record as a courtesy to the earlier developers. The following scripts were used to filter a list of files to edit in place and to clean up the CONTRIBUTED-BY file respectively. These were not added to the glibc sources because they're not expected to be of any use in future given that this is a one time task: https://gist.github.com/siddhesh/b5ecac94eabfd72ed2916d6d8157e7dc https://gist.github.com/siddhesh/15ea1f5e435ace9774f485030695ee02 Reviewed-by: Carlos O'Donell <carlos@redhat.com>
66 lines
1.1 KiB
C
66 lines
1.1 KiB
C
#include <dlfcn.h>
|
|
#include <pthread.h>
|
|
#include <stdio.h>
|
|
#include <stdlib.h>
|
|
|
|
|
|
static void *
|
|
start_routine (void *args)
|
|
{
|
|
int i;
|
|
void **addrs = (void **) args;
|
|
for (i = 0; i < 10000; ++i)
|
|
addrs[i % 1024] = dlsym (NULL, "does_not_exist");
|
|
|
|
return addrs;
|
|
}
|
|
|
|
|
|
static int
|
|
do_test (void)
|
|
{
|
|
pthread_t tid1, tid2, tid3;
|
|
|
|
void *addrs1[1024];
|
|
void *addrs2[1024];
|
|
void *addrs3[1024];
|
|
|
|
if (pthread_create (&tid1, NULL, start_routine, addrs1) != 0)
|
|
{
|
|
puts ("1st create failed");
|
|
exit (1);
|
|
}
|
|
if (pthread_create (&tid2, NULL, start_routine, addrs2) != 0)
|
|
{
|
|
puts ("2nd create failed");
|
|
exit (1);
|
|
}
|
|
if (pthread_create (&tid3, NULL, start_routine, addrs3) != 0)
|
|
{
|
|
puts ("3rd create failed");
|
|
exit (1);
|
|
}
|
|
|
|
if (pthread_join (tid1, NULL) != 0)
|
|
{
|
|
puts ("1st join failed");
|
|
exit (1);
|
|
}
|
|
if (pthread_join (tid2, NULL) != 0)
|
|
{
|
|
puts ("2nd join failed");
|
|
exit (1);
|
|
}
|
|
if (pthread_join (tid3, NULL) != 0)
|
|
{
|
|
puts ("2rd join failed");
|
|
exit (1);
|
|
}
|
|
|
|
return 0;
|
|
}
|
|
|
|
|
|
#define TEST_FUNCTION do_test ()
|
|
#include "../test-skeleton.c"
|