|
@@ -1021,7 +1021,7 @@ int isReachableInternet(void)
|
|
|
{
|
|
|
int result = FAIL;
|
|
|
FILE *fp;
|
|
|
- char cmd[256];
|
|
|
+ char cmd[512];
|
|
|
char buf[512];
|
|
|
char tmp[256];
|
|
|
char isPppGetGw = FALSE;
|
|
@@ -1206,7 +1206,7 @@ int at_command(int uart, char* cmd, char* rx)
|
|
|
//sleep(2); //required to make flush work, for some reason
|
|
|
//DEBUG_INFO("cmd : %s \n", cmd);
|
|
|
tcflush(uart,TCIOFLUSH);
|
|
|
- if(write(uart, cmd, strlen(cmd)) >= sizeof(cmd))
|
|
|
+ if(write(uart, cmd, strlen(cmd)) >= strlen(cmd))
|
|
|
{
|
|
|
usleep(500000);
|
|
|
len = read(uart, rx, 512);
|