diff options
author | Ian C <ianc@noddybox.co.uk> | 2024-12-30 12:41:33 +0000 |
---|---|---|
committer | Ian C <ianc@noddybox.co.uk> | 2024-12-30 12:41:33 +0000 |
commit | 68f33af73d67785a2c6ecba6859d65145bc6ee95 (patch) | |
tree | 2f277cfdabec8d9a8f7f63cc224b649a4010f63c /dload.c | |
parent | aa33cb940bb31c74903fb7dc26e5d2f264064911 (diff) |
Diffstat (limited to 'dload.c')
-rw-r--r-- | dload.c | 16 |
1 files changed, 13 insertions, 3 deletions
@@ -87,6 +87,12 @@ static const char *StatusCode(WifiStatus status) case eWifiInvalidURL: return "Invalid URL"; + case eWifiFailedToSendCommand: + return "Failed to send command to modem"; + + case eWifiBadHTTPStatusCode: + return "Bad HTTP status code"; + case eWifiOK: return "OK"; @@ -108,13 +114,17 @@ int main(int argc, char *argv[]) return EXIT_FAILURE; } - /* if ((status = WifiConnect()) != eWifiOK) { - fprintf(stderr, "%s\n", StatusCode(status)); + fprintf(stderr, "WifiConnect: %s\n", StatusCode(status)); + return EXIT_FAILURE; + } + + if ((status = ConnectURL(0, argv[1], 0)) != eWifiOK) + { + fprintf(stderr, "ConnectURL: %s\n", StatusCode(status)); return EXIT_FAILURE; } - */ return EXIT_SUCCESS; } |