unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
From: Kevin Ryde <user42@zip.com.au>
Subject: cuserid thread safety
Date: Sun, 22 Feb 2004 07:57:44 +1000	[thread overview]
Message-ID: <87d688ksdj.fsf@zip.com.au> (raw)

[-- Attachment #1: Type: text/plain, Size: 79 bytes --]

        * posix.c (scm_cuserid): Use a private result buffer, for reentrancy.


[-- Attachment #2: posix.c.cuserid.diff --]
[-- Type: text/plain, Size: 362 bytes --]

--- posix.c.~1.124.~	2004-02-21 09:19:52.000000000 +1000
+++ posix.c	2004-02-22 07:54:37.000000000 +1000
@@ -1498,9 +1498,10 @@
 	    "information cannot be obtained.")
 #define FUNC_NAME s_scm_cuserid
 {
+  char buf[L_cuserid];
   char * p;
 
-  p = cuserid (NULL);
+  p = cuserid (buf);
   if (!p || !*p)
     return SCM_BOOL_F;
   return scm_makfrom0str (p);

[-- Attachment #3: Type: text/plain, Size: 142 bytes --]

_______________________________________________
Guile-devel mailing list
Guile-devel@gnu.org
http://mail.gnu.org/mailman/listinfo/guile-devel

                 reply	other threads:[~2004-02-21 21:57 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/guile/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87d688ksdj.fsf@zip.com.au \
    --to=user42@zip.com.au \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).