Linux MIPS Architecture development
 help / color / mirror / Atom feed
From: "Kip Walker" <kwalker@broadcom.com>
To: linux-mips@linux-mips.org
Cc: "Ralf Baechle" <ralf@linux-mips.org>
Subject: strncpy etc.
Date: Mon, 18 Nov 2002 14:29:48 -0800	[thread overview]
Message-ID: <3DD969DC.DC6D31BA@broadcom.com> (raw)


Looks like a typo in include/asm-mips/string.h has strncpy returning the
wrong thing -- a pointer to the END of the destination string, rather
than the beginning of the destination string.

Patch for 2.4 is below:

Index: include/asm-mips/string.h
===================================================================
RCS file:
/projects/bbp/cvsroot/systemsw/linux/src/kernel/include/asm-mips/string.h,v
retrieving revision 1.6
diff -u -r1.6 string.h
--- string.h    2002/09/05 22:15:51     1.6
+++ string.h    2002/11/18 22:27:15
@@ -67,7 +67,7 @@
         : "0" (__dest), "1" (__src), "2" (__n)
         : "memory");
 
-  return __dest;
+  return __xdest;
 }
 
 #define __HAVE_ARCH_STRCMP

                 reply	other threads:[~2002-11-18 22:30 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

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

  git send-email \
    --in-reply-to=3DD969DC.DC6D31BA@broadcom.com \
    --to=kwalker@broadcom.com \
    --cc=linux-mips@linux-mips.org \
    --cc=ralf@linux-mips.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