All of lore.kernel.org
 help / color / mirror / Atom feed
* strncpy etc.
@ 2002-11-18 22:29 Kip Walker
  0 siblings, 0 replies; only message in thread
From: Kip Walker @ 2002-11-18 22:29 UTC (permalink / raw)
  To: linux-mips; +Cc: Ralf Baechle


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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2002-11-18 22:30 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-11-18 22:29 strncpy etc Kip Walker

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.