Skip to content

Commit

Permalink
buildability fixes for Arduino
Browse files Browse the repository at this point in the history
  • Loading branch information
Matěj Sychra committed Jul 27, 2018
1 parent a02bcb3 commit 63d5b30
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 4 deletions.
2 changes: 0 additions & 2 deletions src/AESLib.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ String AESLib::decrypt(String msg, byte key[], byte my_iv[]) {

// Base64-decode message to `encrypted` array which stores the ciphertext
int len = msg.length();
Serial.printf("Decrypting message %s of length %i \n", msg.c_str(), len);
char encrypted[len]; // will be always shorter than Base64
int b64len = base64_decode(encrypted, (char*)msg.c_str(), msg.length());

Expand Down Expand Up @@ -50,7 +49,6 @@ void AESLib::decrypt(char * msg, char * plain, byte key[], byte my_iv[]) {

// Base64-decode message to `encrypted` array which stores the ciphertext
int msgLen = strlen(msg);
Serial.printf("Decrypting message %s of length %i \n", msg, msgLen);
char encrypted[msgLen]; // will be always shorter than Base64
int b64len = base64_decode(encrypted, msg, msgLen);

Expand Down
2 changes: 1 addition & 1 deletion src/AES_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
#define PSTR(x) (x)
#else
#if (defined(__AVR__))
#include <avr\pgmspace.h>
#include <avr/pgmspace.h>
#else
#include <pgmspace.h>
#endif
Expand Down
2 changes: 1 addition & 1 deletion src/base64.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "Base64.h"

#if (defined(__AVR__))
#include <avr\pgmspace.h>
#include <avr/pgmspace.h>
#else
#include <pgmspace.h>
#endif
Expand Down

0 comments on commit 63d5b30

Please sign in to comment.