Skip to content

Commit 6d55570

Browse files
authored
Merge pull request #97 from hessu/feature/threads
Set pthreads title names on Linux
2 parents 9779451 + 1d5a0a5 commit 6d55570

11 files changed

Lines changed: 1768 additions & 1340 deletions

File tree

src/ac-hdrs.h.in

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,6 @@
3333
/* Have libz */
3434
#undef HAVE_LIBZ
3535

36-
/* Define to 1 if you have the <memory.h> header file. */
37-
#undef HAVE_MEMORY_H
38-
3936
/* Define to 1 if you have the <netinet/sctp.h> header file. */
4037
#undef HAVE_NETINET_SCTP_H
4138

@@ -48,6 +45,9 @@
4845
/* Linux process control prctl.h */
4946
#undef HAVE_PRCTL_H
5047

48+
/* pthread_setname_np available */
49+
#undef HAVE_PTHREAD_SETNAME_NP
50+
5151
/* Define to 1 if you have the `putenv' function. */
5252
#undef HAVE_PUTENV
5353

@@ -63,6 +63,9 @@
6363
/* Define to 1 if you have the <stdint.h> header file. */
6464
#undef HAVE_STDINT_H
6565

66+
/* Define to 1 if you have the <stdio.h> header file. */
67+
#undef HAVE_STDIO_H
68+
6669
/* Define to 1 if you have the <stdlib.h> header file. */
6770
#undef HAVE_STDLIB_H
6871

@@ -123,5 +126,7 @@
123126
/* Define to the version of this package. */
124127
#undef PACKAGE_VERSION
125128

126-
/* Define to 1 if you have the ANSI C header files. */
129+
/* Define to 1 if all of the C90 standard headers exist (not just the ones
130+
required in a freestanding environment). This macro is provided for
131+
backward compatibility; new code need not use it. */
127132
#undef STDC_HEADERS

src/accept.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1394,6 +1394,7 @@ void accept_thread(void *asdf)
13941394
int poll_n = 0;
13951395
struct listen_t *l;
13961396

1397+
thread_name_set("aprsc accept");
13971398
pthreads_profiling_reset("accept");
13981399

13991400
sigemptyset(&sigs_to_block);

src/aprsc.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -763,6 +763,7 @@ void time_thread(void *asdf)
763763
hlog(LOG_INFO, "Time thread starting: using gettimeofday");
764764
#endif
765765

766+
thread_name_set("aprsc time");
766767
pthreads_profiling_reset("time");
767768

768769
sigemptyset(&sigs_to_block);

0 commit comments

Comments
 (0)