mirror of
https://github.com/zeek/zeek.git
synced 2025-10-17 14:08:20 +00:00
Fix another compiler warning
This commit is contained in:
parent
1d33883dfc
commit
20f11ad237
1 changed files with 5 additions and 1 deletions
|
@ -208,7 +208,11 @@ void init_alternative_mode()
|
|||
fprintf(fp_func_init, "// %s\n\n", auto_gen_comment);
|
||||
|
||||
static char guard[1024];
|
||||
getcwd(guard, sizeof(guard));
|
||||
if ( getcwd(guard, sizeof(guard)) == NULL )
|
||||
{
|
||||
fprintf(stderr, "Error: cannot get current working directory\n");
|
||||
err_exit();
|
||||
}
|
||||
strncat(guard, "/", sizeof(guard) - strlen(guard) - 1);
|
||||
strncat(guard, input_filename, sizeof(guard) - strlen(guard) - 1);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue