# --- T2-COPYRIGHT-NOTE-BEGIN --- # This copyright note is auto-generated by ./scripts/Create-CopyPatch. # # T2 SDE: package/.../dietlibc/stpcpy.patch # Copyright (C) 2012 The T2 SDE Project # # More information can be found in the files COPYING and README. # # This patch file is dual-licensed. It is available under the license the # patched project is licensed under, as long as it is an OpenSource license # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms # of the GNU General Public License as published by the Free Software # Foundation; either version 2 of the License, or (at your option) any later # version. # --- T2-COPYRIGHT-NOTE-END --- Needed by latest GCC-4.7 "string length optimization pass", ... - Rene Rebe --- /dev/null 2005-11-24 11:09:35.213013250 +0100 +++ dietlibc-0.29/lib/stpcpy.c 2005-11-26 23:48:26.000000000 +0100 @@ -0,0 +1,9 @@ +#include +#include "dietfeatures.h" +#include + +char *stpcpy(char * __restrict__ dest, const char * __restrict__ src) { + for (; __likely(*src); src++) *dest++ = *src; + *dest = *src; /* NULL sentinal */ + return dest; +}