Skip to content
Snippets Groups Projects
Commit eb1e3a39 authored by Daniel Stenberg's avatar Daniel Stenberg
Browse files

operate: avoid NULL dereference

Coverity CID 1241948. dumpeasysrc() would get called with
config->current set to NULL which could be dereferenced by a warnf()
call.
parent 87c8e00b
No related branches found
No related tags found
No related merge requests found
......@@ -1848,6 +1848,9 @@ CURLcode operate(struct GlobalConfig *config, int argc, argv_item_t argv[])
/* Cleanup the libcurl source output */
easysrc_cleanup();
/* set current back to first so that isn't NULL */
config->current = config->first;
/* Dump the libcurl code if previously enabled */
dumpeasysrc(config);
#endif
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment