Commit 4b87169d authored by Eli Zaretskii's avatar Eli Zaretskii

Avoid a compilation warning in w32.c

* src/w32.c (logon_network_drive): Avoid compilation warning
about strncpy arguments.
parent c4dd5a73
Pipeline #2963 failed with stage
in 3 minutes and 48 seconds
......@@ -3918,7 +3918,7 @@ logon_network_drive (const char *path)
return;
n_slashes = 2;
strncpy (share, path, MAX_UTF8_PATH);
strncpy (share, path, MAX_UTF8_PATH - 1);
/* Truncate to just server and share name. */
for (p = share + 2; *p && p < share + MAX_UTF8_PATH; p++)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment