forked from osmocom/wireshark
sharkd_session.c: fix a warning reported by gcc 10
warning: ‘%s’ directive argument is null [-Wformat-overflow=] 544 | fprintf(stderr, "load: filename=%s\n", tok_file); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Change-Id: I583a94308ad53b461606053def17e8537eec8d65 Reviewed-on: https://code.wireshark.org/review/37195 Petri-Dish: Pascal Quantin <pascal@wireshark.org> Tested-by: Petri Dish Buildbot Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
This commit is contained in:
parent
4b67b72d2a
commit
536f5b466b
|
@ -541,11 +541,11 @@ sharkd_session_process_load(const char *buf, const jsmntok_t *tokens, int count)
|
|||
const char *tok_file = json_find_attr(buf, tokens, count, "file");
|
||||
int err = 0;
|
||||
|
||||
fprintf(stderr, "load: filename=%s\n", tok_file);
|
||||
|
||||
if (!tok_file)
|
||||
return;
|
||||
|
||||
fprintf(stderr, "load: filename=%s\n", tok_file);
|
||||
|
||||
if (sharkd_cf_open(tok_file, WTAP_TYPE_AUTO, FALSE, &err) != CF_OK)
|
||||
{
|
||||
sharkd_json_simple_reply(err, NULL);
|
||||
|
|
Loading…
Reference in New Issue