int hour = -1;
int min = -1;
- char *tempstr = NULL;
-
*exist = 0;
ret = regexec(®[3], str, 1, pmatch, 0);
if (0 == ret) {
SLOG(LOG_ERROR, TAG_VCCMD, "[ERROR] Invalid string length");
return VC_ERROR_OPERATION_FAILED;
}
- tempstr = strndup(str + pmatch[1].rm_so, (size_t)len);
+ char *tempstr = strndup(str + pmatch[1].rm_so, (size_t)len);
if (NULL == tempstr) {
SLOG(LOG_ERROR, TAG_VCCMD, "[ERROR] Memory allocation is failed");
SLOG(LOG_ERROR, TAG_VCCMD, "[ERROR] Invalid string length");
return VC_ERROR_OPERATION_FAILED;
}
- tempstr = strndup(str + pmatch[1].rm_so, (size_t)len);
+ char *tempstr = strndup(str + pmatch[1].rm_so, (size_t)len);
if (NULL == tempstr) {
SLOG(LOG_ERROR, TAG_VCCMD, "[ERROR] Memory allocation is failed");
int min = -1;
int sidx = -1;
int eidx = -1;
- char *tempstr = NULL;
*exist = 0;
ret = regexec(®[0], str, 5, pmatch, 0);
SLOG(LOG_ERROR, TAG_VCCMD, "[ERROR] Invalid string length");
return VC_ERROR_OPERATION_FAILED;
}
- tempstr = strndup(str + pmatch[1].rm_so, (size_t)len);
+ char *tempstr = strndup(str + pmatch[1].rm_so, (size_t)len);
if (NULL == tempstr) {
SLOG(LOG_ERROR, TAG_VCCMD, "[ERROR] Memory allocation is failed");
idx = 1;
len = pmatch[idx].rm_eo - pmatch[idx].rm_so;
if (0 < len) {
- tempstr = strndup(str + pmatch[idx].rm_so, (size_t)len);
+ char *tempstr = strndup(str + pmatch[idx].rm_so, (size_t)len);
if (NULL == tempstr) {
SLOG(LOG_ERROR, TAG_VCCMD, "[ERROR] Memory allocation is failed");