mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-11-03 03:41:04 +01:00
CommandOption: fixes segfault with unknown module
This commit is contained in:
@@ -178,7 +178,7 @@ static bool parseStructureCommand(
|
||||
}
|
||||
}
|
||||
|
||||
if (fn == genJsonResult) {
|
||||
if (data->resultDoc) {
|
||||
yyjson_mut_doc* doc = data->resultDoc;
|
||||
yyjson_mut_val* module = yyjson_mut_arr_add_obj(doc, doc->root);
|
||||
yyjson_mut_obj_add_str(doc, module, "type", line);
|
||||
|
||||
Reference in New Issue
Block a user