mirror of
https://github.com/vgmstream/vgmstream.git
synced 2024-11-28 00:20:47 +01:00
cleanup: fix crap
This commit is contained in:
parent
6fe61717d2
commit
0b2a134c62
@ -230,7 +230,7 @@ static bool parse_config(cli_config_t* cfg, int argc, char** argv) {
|
||||
goto fail;
|
||||
#ifdef HAVE_JSON
|
||||
case 'V':
|
||||
print_json_version();
|
||||
print_json_version(VGMSTREAM_VERSION);
|
||||
goto fail;
|
||||
case 'I':
|
||||
cfg->print_metajson = true;
|
||||
@ -576,7 +576,7 @@ static bool convert_file(cli_config_t* cfg) {
|
||||
#ifdef HAVE_JSON
|
||||
}
|
||||
else {
|
||||
print_json_info(vgmstream, cfg);
|
||||
print_json_info(vgmstream, cfg, VGMSTREAM_VERSION);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -69,8 +69,8 @@ void print_tags(cli_config_t* cfg);
|
||||
void print_title(VGMSTREAM* vgmstream, cli_config_t* cfg);
|
||||
|
||||
#ifdef HAVE_JSON
|
||||
void print_json_version();
|
||||
void print_json_info(VGMSTREAM* vgmstream, cli_config_t* cfg);
|
||||
void print_json_version(const char* vgmstream_version);
|
||||
void print_json_info(VGMSTREAM* vgm, cli_config_t* cfg, const char* vgmstream_version);
|
||||
#endif
|
||||
|
||||
|
||||
|
@ -184,7 +184,7 @@ void print_title(VGMSTREAM* vgmstream, cli_config_t* cfg) {
|
||||
}
|
||||
|
||||
#ifdef HAVE_JSON
|
||||
void print_json_version() {
|
||||
void print_json_version(const char* vgmstream_version) {
|
||||
size_t extension_list_len;
|
||||
size_t common_extension_list_len;
|
||||
const char** extension_list;
|
||||
@ -205,7 +205,7 @@ void print_json_version() {
|
||||
json_array_append(cext_list, cext);
|
||||
}
|
||||
|
||||
json_t* version_string = json_string(VGMSTREAM_VERSION);
|
||||
json_t* version_string = json_string(vgmstream_version);
|
||||
|
||||
json_t* final_object = json_object();
|
||||
json_object_set(final_object, "version", version_string);
|
||||
@ -219,8 +219,8 @@ void print_json_version() {
|
||||
json_dumpf(final_object, stdout, JSON_COMPACT);
|
||||
}
|
||||
|
||||
void print_json_info(VGMSTREAM* vgm, cli_config_t* cfg) {
|
||||
json_t* version_string = json_string(VGMSTREAM_VERSION);
|
||||
void print_json_info(VGMSTREAM* vgm, cli_config_t* cfg, const char* vgmstream_version) {
|
||||
json_t* version_string = json_string(vgmstream_version);
|
||||
vgmstream_info info;
|
||||
describe_vgmstream_info(vgm, &info);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user