From 5df9084d8e484372b8c3a7d238d0be45620c3d81 Mon Sep 17 00:00:00 2001 From: Sandeep Mistry Date: Fri, 17 Jun 2016 15:34:49 -0400 Subject: [PATCH] Correct some warnings --- HttpClient.cpp | 5 ++++- b64.cpp | 2 ++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/HttpClient.cpp b/HttpClient.cpp index dc1bb5a..3dcf252 100644 --- a/HttpClient.cpp +++ b/HttpClient.cpp @@ -252,7 +252,7 @@ int HttpClient::responseStatusCode() // Where HTTP-Version is of the form: // HTTP-Version = "HTTP" "/" 1*DIGIT "." 1*DIGIT - char c = '\0'; + int c = '\0'; do { // Make sure the status code is reset, and likewise the state. This @@ -311,6 +311,9 @@ int HttpClient::responseStatusCode() case eStatusCodeRead: // We're just waiting for the end of the line now break; + + default: + break; }; // We read something, reset the timeout counter timeoutStart = millis(); diff --git a/b64.cpp b/b64.cpp index b926cad..683d60a 100644 --- a/b64.cpp +++ b/b64.cpp @@ -66,5 +66,7 @@ int b64_encode(const unsigned char* aInput, int aInputLen, unsigned char* aOutpu b64_encode(&aInput[i*3], aInputLen % 3, &aOutput[i*4], aOutputLen - (i*4)); } } + + return ((aInputLen+2)/3)*4; }