tweaks: exclude an unlikely error message from the tiny version

master
Benno Schulenberg 2018-03-05 12:45:19 +01:00
parent 1f7384ebd2
commit 899bf0ae3a
1 changed files with 2 additions and 1 deletions

View File

@ -378,9 +378,10 @@ char *mallocstrncpy(char *dest, const char *src, size_t n)
if (src == NULL)
src = "";
#ifndef NANO_TINY
if (src == dest)
fprintf(stderr, "\r*** Copying a string to itself -- please report a bug ***");
#endif
dest = charealloc(dest, n);
strncpy(dest, src, n);