diff options
author | ꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id> | 2021-07-24 13:09:19 +0800 |
---|---|---|
committer | ꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id> | 2021-07-24 13:09:19 +0800 |
commit | b960919d909c75dc9c483846c2acec5315a0b7db (patch) | |
tree | 076f538011e6311320cdbaffb7ae0eb4caa800bc | |
parent | 218418f3623da5f07cf8428d1d8687b9d5fbc4ae (diff) |
Make sure services is filled with NULL
-rw-r--r-- | pikul.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -201,8 +201,10 @@ char *pikul_html(char *origins[], char *destinations[], double weight, struct pikul_service **services[PIKUL_END]; bool no_service = true; for (enum pikul_company company = PIKUL; company < PIKUL_END; company++) { - if (!shipping_list[company]) + if (!shipping_list[company]) { + services[company] = NULL; continue; + } services[company] = pikul_services(company, origins[company], destinations[company], weight); if (services[company] && services[company][0]) |