Change-Id: I1ddf456d600a5c0401b88dcc00a422d918b70523
( strlen( str ) > 0 ) && \
( strlen( str ) < PLAYER_INI_MAX_STRLEN ) ) \
{ \
- strcpy ( x_item, str ); \
+ strncpy ( x_item, str, PLAYER_INI_MAX_STRLEN-1 ); \
} \
else \
{ \
- strcpy ( x_item, x_default ); \
+ strncpy ( x_item, x_default, PLAYER_INI_MAX_STRLEN-1 ); \
} \
}while(0)
{
if (strlen(path))
{
- strcpy(data->uri, uri);
+ strncpy(data->uri, uri, MM_MAX_URL_LEN-1);
data->uri_type = MM_PLAYER_URI_TYPE_MS_BUFF;
ret = MM_ERROR_NONE;
}
ERROR:
MMPLAYER_PLAYBACK_UNLOCK(player);
- if (!player->msg_posted)
+ if (player && !player->msg_posted)
{
MMPLAYER_POST_MSG(player, MM_MESSAGE_ERROR, &msg_param);
player->msg_posted = TRUE;