Commit 2ce63e9
sha1_name: use strlcpy() to copy strings
Use strlcpy() instead of calling strncpy() and then setting the last
byte of the target buffer to NUL explicitly. This shortens and
simplifies the code a bit.
Signed-of-by: Rene Scharfe <[email protected]>
Signed-off-by: Junio C Hamano <[email protected]>1 parent 68d6d6e commit 2ce63e9
1 file changed
+2
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1384 | 1384 | | |
1385 | 1385 | | |
1386 | 1386 | | |
1387 | | - | |
1388 | | - | |
1389 | | - | |
| 1387 | + | |
1390 | 1388 | | |
1391 | 1389 | | |
1392 | 1390 | | |
| |||
1436 | 1434 | | |
1437 | 1435 | | |
1438 | 1436 | | |
1439 | | - | |
1440 | | - | |
1441 | | - | |
| 1437 | + | |
1442 | 1438 | | |
1443 | 1439 | | |
1444 | 1440 | | |
| |||
0 commit comments