From: Kevin Day Date: Sun, 21 Jul 2019 21:03:28 +0000 (-0500) Subject: Update: use memcpy instead of strncat X-Git-Tag: 0.4.3~25 X-Git-Url: https://git.kevux.org/?a=commitdiff_plain;h=a25605dd821b872330cd0706a4200f415348f8ec;p=fll Update: use memcpy instead of strncat --- diff --git a/level_1/fl_directory/c/directory.c b/level_1/fl_directory/c/directory.c index 5a6cad3..c8e47d6 100644 --- a/level_1/fl_directory/c/directory.c +++ b/level_1/fl_directory/c/directory.c @@ -44,7 +44,7 @@ extern "C"{ return status; } - strncat(names->array[names->used].string, listing[counter]->d_name, size); + memcpy(names->array[names->used].string, listing[counter]->d_name, sizeof(f_autochar) * size); names->array[names->used].used = size; names->used++; }