public inbox for libc-ports@sourceware.org
 help / color / mirror / Atom feed
From: Richard Henderson <rth@twiddle.net>
To: libc-ports@sourceware.org
Subject: [PATCH 3/4] alpha: Avoid fgets plt entry
Date: Wed, 30 May 2012 23:11:00 -0000	[thread overview]
Message-ID: <1338419462-7572-3-git-send-email-rth@twiddle.net> (raw)
In-Reply-To: <1338419462-7572-1-git-send-email-rth@twiddle.net>

And since the FILE is function local, avoid locking too.
---
 ChangeLog.alpha                        |    3 +++
 sysdeps/unix/sysv/linux/alpha/ioperm.c |    2 +-
 2 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/ChangeLog.alpha b/ChangeLog.alpha
index e327242..246345a 100644
--- a/ChangeLog.alpha
+++ b/ChangeLog.alpha
@@ -1,5 +1,8 @@
 2012-05-30  Richard Henderson  <rth@twiddle.net>
 
+	* sysdeps/unix/sysv/linux/alpha/ioperm.c (process_cpuinfo): Use
+	fgets_unlocked.
+
 	* sysdeps/alpha/Implies: Include ieee754/dbl-64/wordsize-64.
 
 	* sysdeps/alpha/alphaev6/fpu/e_sqrt.S: Use dynamic rounding.
diff --git a/sysdeps/unix/sysv/linux/alpha/ioperm.c b/sysdeps/unix/sysv/linux/alpha/ioperm.c
index 8b6c830..686c7ed 100644
--- a/sysdeps/unix/sysv/linux/alpha/ioperm.c
+++ b/sysdeps/unix/sysv/linux/alpha/ioperm.c
@@ -504,7 +504,7 @@ process_cpuinfo(struct cpuinfo_data *data)
 
   while (1)
     {
-      if (fgets (dummy, 256, fp) == NULL)
+      if (fgets_unlocked (dummy, 256, fp) == NULL)
 	break;
       if (!got_type &&
 	  sscanf (dummy, "system type : %256[^\n]\n", data->systype) == 1)
-- 
1.7.7.6

  parent reply	other threads:[~2012-05-30 23:11 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-30 23:11 [PATCH 1/4] alpha: Use dynamic rounding with sqrt insn Richard Henderson
2012-05-30 23:11 ` [PATCH 2/4] alpha: Use dbl-64/wordsize-64 Richard Henderson
2012-05-30 23:11 ` Richard Henderson [this message]
2012-05-30 23:11 ` [PATCH 4/4] alpha: Remove __connect_internal alias Richard Henderson

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

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

  git send-email \
    --in-reply-to=1338419462-7572-3-git-send-email-rth@twiddle.net \
    --to=rth@twiddle.net \
    --cc=libc-ports@sourceware.org \
    /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).