From ac044784a6ce64ff15610d4b70750065a7f01b80 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Tue, 1 Sep 2015 21:07:54 +0200 Subject: start on makefile and fixing warnings and errors MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- src/string/strcpy.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/string/strcpy.c') diff --git a/src/string/strcpy.c b/src/string/strcpy.c index dfbdc75..17dd339 100644 --- a/src/string/strcpy.c +++ b/src/string/strcpy.c @@ -16,7 +16,6 @@ * along with this program. If not, see . */ #include -#include @@ -93,7 +92,7 @@ char* strstrcpy(char* restrict whither, const char* restrict whence, const char* { const char* stop = str == NULL ? NULL : strstr(whence, str); size_t n = stop == NULL ? strlen(whence) : (size_t)(stop - whence); - char* r = stop == NULL ? NULL ? whither + n; + char* r = stop == NULL ? NULL : (whither + n); memcpy(whither, whence, n); whither[n] = 0; return r; -- cgit v1.2.3-70-g09d2