221 |
"CB", /* Currently selected memory */ |
"CB", /* Currently selected memory */ |
222 |
}; |
}; |
223 |
|
|
224 |
|
#define NR_MEMORIES (sizeof (memorynames) / sizeof ((memorynames)[0])) |
225 |
|
|
226 |
typedef struct { |
typedef struct { |
227 |
char *str; |
char *str; |
228 |
at_charset charset; |
at_charset charset; |
510 |
gn_error ret = GN_ERR_NONE; |
gn_error ret = GN_ERR_NONE; |
511 |
|
|
512 |
if (mt != drvinst->memorytype) { |
if (mt != drvinst->memorytype) { |
513 |
|
if (mt >= NR_MEMORIES) |
514 |
|
return GN_ERR_INVALIDMEMORYTYPE; |
515 |
sprintf(req, "AT+CPBS=\"%s\"\r", memorynames[mt]); |
sprintf(req, "AT+CPBS=\"%s\"\r", memorynames[mt]); |
516 |
ret = sm_message_send(13, GN_OP_Init, req, state); |
ret = sm_message_send(13, GN_OP_Init, req, state); |
517 |
if (ret) |
if (ret) |
1366 |
data->sms_status->folders_count = 0; |
data->sms_status->folders_count = 0; |
1367 |
|
|
1368 |
data->sms_status->new_message_store = GN_MT_ME; |
data->sms_status->new_message_store = GN_MT_ME; |
1369 |
for (i = 0; i < sizeof(memorynames)/sizeof(char *); i++) { |
for (i = 0; i < NR_MEMORIES; i++) { |
1370 |
if (strcmp(store, memorynames[i]) == 0) { |
if (strcmp(store, memorynames[i]) == 0) { |
1371 |
data->sms_status->new_message_store = i; |
data->sms_status->new_message_store = i; |
1372 |
break; |
break; |