Permalink
Browse files

Remove rands magic number

Patch by: michaelortmann
  • Loading branch information...
michaelortmann authored and vanosg committed Nov 1, 2018
1 parent 77aa291 commit 82bd496ec1ae5a1dab2112c75c86452f3a91638e
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/mod/filesys.mod/filesys.c
@@ -714,7 +714,7 @@ static char *mktempfile(char *filename)
char rands[8], *tempname, *fn = filename;
int l;
make_rand_str(rands, 7);
make_rand_str(rands, sizeof rands - 1);
l = strlen(filename);
if ((l + MKTEMPFILE_TOT) > NAME_MAX) {
fn[NAME_MAX - MKTEMPFILE_TOT] = 0;

0 comments on commit 82bd496

Please sign in to comment.