Skip to content

Commit 144d828

Browse files
committed
More thread error improvments.
1 parent 2f52236 commit 144d828

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/tools/thread/thread_test.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group
77
* Portions Copyright (c) 1994, Regents of the University of California
88
*
9-
* $PostgreSQL: pgsql/src/tools/thread/thread_test.c,v 1.24 2004/04/26 00:36:18 momjian Exp $
9+
* $PostgreSQL: pgsql/src/tools/thread/thread_test.c,v 1.25 2004/04/26 00:38:25 momjian Exp $
1010
*
1111
* This program tests to see if your standard libc functions use
1212
* pthread_setspecific()/pthread_getspecific() to be thread-safe.
@@ -94,7 +94,7 @@ main(int argc, char *argv[])
9494
#if !defined(HAVE_GETADDRINFO) && !defined(HAVE_GETHOSTBYNAME_R)
9595
if (gethostname(myhostname, MAXHOSTNAMELEN) != 0)
9696
{
97-
fprintf(stderr, "can not get local hostname, exiting\n");
97+
fprintf(stderr, "Can not get local hostname **\nexiting\n");
9898
exit(1);
9999
}
100100
#endif
@@ -202,7 +202,7 @@ func_call_1(void)
202202
open("/tmp/thread_test.1", O_RDWR | O_CREAT | O_EXCL, 0600) >= 0)
203203
{
204204
fprintf(stderr, "Could not create file in /tmp or\n");
205-
fprintf(stderr, "could not generate failure for create file in /tmp, exiting\n");
205+
fprintf(stderr, "Could not generate failure for create file in /tmp **\nexiting\n");
206206
exit(1);
207207
}
208208

@@ -215,7 +215,7 @@ func_call_1(void)
215215
sched_yield();
216216
if (errno != EEXIST)
217217
{
218-
fprintf(stderr, "errno not thread-safe; exiting\n");
218+
fprintf(stderr, "errno not thread-safe **\nexiting\n");
219219
unlink("/tmp/thread_test.1");
220220
exit(1);
221221
}
@@ -271,7 +271,7 @@ func_call_2(void)
271271
/* open non-existant file */
272272
if (open("/tmp/thread_test.2", O_RDONLY, 0600) >= 0)
273273
{
274-
fprintf(stderr, "Read-only open succeeded without create, exiting\n");
274+
fprintf(stderr, "Read-only open succeeded without create **\nexiting\n");
275275
exit(1);
276276
}
277277

@@ -284,7 +284,7 @@ func_call_2(void)
284284
sched_yield();
285285
if (errno != ENOENT)
286286
{
287-
fprintf(stderr, "errno not thread-safe; exiting\n");
287+
fprintf(stderr, "errno not thread-safe **\nexiting\n");
288288
unlink("/tmp/thread_test.A");
289289
exit(1);
290290
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy