goto _ERR_CAMCORDER_AUDIO_COMMAND;
}
- info->filename = strdup(temp_filename);
+ info->filename = g_strdup(temp_filename);
if (!info->filename) {
_mmcam_dbg_err("STRDUP was failed");
goto _ERR_CAMCORDER_AUDIO_COMMAND;
if (info->filename) {
_mmcam_dbg_log("file delete(%s)", info->filename);
unlink(info->filename);
- g_free(info->filename);
- info->filename = NULL;
+ SAFE_G_FREE(info->filename);
}
break;
/* Send recording report message to application */
msg.id = MM_MESSAGE_CAMCORDER_AUDIO_CAPTURED;
- report = (MMCamRecordingReport*) malloc(sizeof(MMCamRecordingReport));
+ report = (MMCamRecordingReport*) g_malloc(sizeof(MMCamRecordingReport));
if (!report) {
_mmcam_dbg_err("Recording report fail(%s). Out of memory.", info->filename);
return FALSE;
}
/* END TAG HERE */
- report->recording_filename = strdup(info->filename);
+ report->recording_filename = g_strdup(info->filename);
msg.param.data= report;
_mmcamcorder_send_message(handle, &msg);
sc->isMaxsizePausing = FALSE;
sc->isMaxtimePausing = FALSE;
- g_free(info->filename);
- info->filename = NULL;
+ SAFE_G_FREE(info->filename);
_mmcam_dbg_err("_MMCamcorder_CMD_COMMIT : end");