diff --git a/modules/codec/webvtt/subsvtt.c b/modules/codec/webvtt/subsvtt.c index b69260ac44c211b8e3fcd515a920a48a6cc08e9b..ca4d4bf37e6702d453b8398a0211329f1d5aaf71 100644 --- a/modules/codec/webvtt/subsvtt.c +++ b/modules/codec/webvtt/subsvtt.c @@ -734,7 +734,7 @@ static bool webvtt_domnode_Match_Attribute( const webvtt_dom_node_t *p_node, psz_start = p_tagnode->psz_attrs; if( !p_matchsel ) /* attribute check only */ - return strlen( psz_start ) > 0; + return *psz_start != '\0'; return MatchAttribute( psz_start, p_matchsel->psz_name, p_matchsel->match ); } diff --git a/modules/gui/macosx/coreinteraction/VLCVideoFilterHelper.m b/modules/gui/macosx/coreinteraction/VLCVideoFilterHelper.m index e0ef0cd438d596cb4d04859e8cb5476848bbc0fb..3b1ea31e8d4c0f278de4a2e1609cdbea2e091fc9 100644 --- a/modules/gui/macosx/coreinteraction/VLCVideoFilterHelper.m +++ b/modules/gui/macosx/coreinteraction/VLCVideoFilterHelper.m @@ -99,7 +99,7 @@ } /* Remove trailing : : */ - if (strlen(psz_string) > 0 && *(psz_string + strlen(psz_string) -1) == ':') + if (*psz_string != '\0' && *(psz_string + strlen(psz_string) -1) == ':') *(psz_string + strlen(psz_string) -1) = '\0'; } else { free(psz_string); diff --git a/modules/stream_filter/hds/hds.c b/modules/stream_filter/hds/hds.c index 65744ef01276ed9c02a6328903dd2b918310563f..c8944ccc59ef90b601a95072b317ea955d6b4ebb 100644 --- a/modules/stream_filter/hds/hds.c +++ b/modules/stream_filter/hds/hds.c @@ -761,7 +761,7 @@ static uint8_t* download_chunk( stream_t *s, const char* quality = ""; char* server_base = sys->base_url; if( stream->server_entry_count > 0 && - strlen(stream->server_entries[0]) > 0 ) + stream->server_entries[0][0] != '\0' ) { server_base = stream->server_entries[0]; } diff --git a/modules/stream_out/rtsp.c b/modules/stream_out/rtsp.c index 8d79803c8e036ee85b01ea4c9e1602461212e24d..4bf26a9140db32aeccf5a87db14ecc8d470235fc 100644 --- a/modules/stream_out/rtsp.c +++ b/modules/stream_out/rtsp.c @@ -196,7 +196,7 @@ static void RtspTrackClose( rtsp_strack_t *tr ); char *RtspAppendTrackPath( rtsp_stream_id_t *id, const char *base ) { - const char *sep = strlen( base ) > 0 && base[strlen( base ) - 1] == '/' ? + const char *sep = *base != '\0' && base[strlen( base ) - 1] == '/' ? "" : "/"; char *url;