From 80ba00a8101b3c8213d9f560a791457a54ec8a12 Mon Sep 17 00:00:00 2001 From: =?utf8?q?R=C3=A9mi=20Denis-Courmont?= Date: Sun, 17 May 2009 11:16:03 +0300 Subject: [PATCH] Avoid ?: GCC-ism --- modules/access/dvb/linux_dvb.c | 6 ++++-- modules/access/ftp.c | 12 +++++++----- modules/access/http.c | 20 ++++++++++---------- modules/access/v4l2.c | 6 ++++-- modules/access/vcd/cdrom.c | 9 ++++++--- modules/access_output/udp.c | 2 +- modules/codec/subtitles/subsdec.c | 7 ++++--- modules/demux/ts.c | 6 ++++-- modules/services_discovery/sap.c | 8 +++++--- modules/stream_out/transcode.c | 12 ++++++++---- modules/video_filter/postproc.c | 6 ++++-- modules/video_output/msw/direct3d.c | 3 ++- src/misc/filter_chain.c | 2 +- src/misc/variables.c | 10 +++++++--- src/modules/modules.c | 2 +- src/network/httpd.c | 2 +- src/network/io.c | 4 ++-- src/network/tcp.c | 5 +++-- src/network/udp.c | 9 +++++---- src/video_output/video_output.c | 5 +++-- 20 files changed, 82 insertions(+), 54 deletions(-) diff --git a/modules/access/dvb/linux_dvb.c b/modules/access/dvb/linux_dvb.c index 2654fd1604..acab3d8868 100644 --- a/modules/access/dvb/linux_dvb.c +++ b/modules/access/dvb/linux_dvb.c @@ -414,7 +414,8 @@ static int ScanParametersDvbC( access_t *p_access, scan_parameter_t *p_scan ) /* */ p_scan->frequency.i_min = p_frontend->info.frequency_min; p_scan->frequency.i_max = p_frontend->info.frequency_max; - p_scan->frequency.i_step = p_frontend->info.frequency_stepsize ?: 166667; + p_scan->frequency.i_step = p_frontend->info.frequency_stepsize + ? p_frontend->info.frequency_stepsize : 166667; p_scan->frequency.i_count = (p_scan->frequency.i_max-p_scan->frequency.i_min)/p_scan->frequency.i_step; /* */ @@ -436,7 +437,8 @@ static int ScanParametersDvbT( access_t *p_access, scan_parameter_t *p_scan ) /* */ p_scan->frequency.i_min = p_frontend->info.frequency_min; p_scan->frequency.i_max = p_frontend->info.frequency_max; - p_scan->frequency.i_step = p_frontend->info.frequency_stepsize ?: 166667; + p_scan->frequency.i_step = p_frontend->info.frequency_stepsize + ? p_frontend->info.frequency_stepsize : 166667; p_scan->frequency.i_count = (p_scan->frequency.i_max-p_scan->frequency.i_min)/p_scan->frequency.i_step; /* */ diff --git a/modules/access/ftp.c b/modules/access/ftp.c index c6ac6df163..b3dc2c911b 100644 --- a/modules/access/ftp.c +++ b/modules/access/ftp.c @@ -334,12 +334,14 @@ static int InOpen( vlc_object_t *p_this ) goto exit_error; /* get size */ - if( ftp_SendCommand( p_this, p_sys, "SIZE %s", p_sys->url.psz_path ? : "" ) < 0 || - ftp_ReadCommand( p_this, p_sys, NULL, &psz_arg ) != 2 ) + if( ftp_SendCommand( p_this, p_sys, "SIZE %s", p_sys->url.psz_path + ? p_sys->url.psz_path : "" ) < 0 + || ftp_ReadCommand( p_this, p_sys, NULL, &psz_arg ) != 2 ) { msg_Dbg( p_access, "cannot get file size" ); msg_Dbg( p_access, "will try to get directory contents" ); - if( ftp_SendCommand( p_this, p_sys, "CWD %s", p_sys->url.psz_path ?: "" ) < 0 || + if( ftp_SendCommand( p_this, p_sys, "CWD %s", p_sys->url.psz_path + ? p_sys->url.psz_path : "" ) < 0 || ftp_ReadCommand( p_this, p_sys, NULL, &psz_arg ) != 2 ) { msg_Err( p_access, "file or directory doesn't exist" ); @@ -799,8 +801,8 @@ static int ftp_StartStream( vlc_object_t *p_access, access_sys_t *p_sys, /* "1xx" message */ if( ftp_SendCommand( p_access, p_sys, "%s %s", p_sys->out ? "STOR" : "RETR", - p_sys->url.psz_path ?: "" ) < 0 || - ftp_ReadCommand( p_access, p_sys, &i_answer, NULL ) > 2 ) + p_sys->url.psz_path ? p_sys->url.psz_path : "" ) < 0 + || ftp_ReadCommand( p_access, p_sys, &i_answer, NULL ) > 2 ) { msg_Err( p_access, "cannot retrieve file" ); return VLC_EGENERIC; diff --git a/modules/access/http.c b/modules/access/http.c index f94d7cd81e..16544e1c3e 100644 --- a/modules/access/http.c +++ b/modules/access/http.c @@ -248,7 +248,7 @@ static int OpenWithCookies( vlc_object_t *p_this, vlc_array_t *cookies ) char *psz, *p; /* Only forward an store cookies if the corresponding option is activated */ bool b_forward_cookies = var_CreateGetBool( p_access, "http-forward-cookies" ); - vlc_array_t * saved_cookies = b_forward_cookies ? (cookies ?: vlc_array_new()) : NULL; + vlc_array_t * saved_cookies = b_forward_cookies ? (cookies ? cookies : vlc_array_new()) : NULL; /* Set up p_access */ STANDARD_READ_ACCESS_INIT; @@ -1735,8 +1735,8 @@ static char *AuthDigest( access_t *p_access, vlc_url_t *p_url, http_auth_t *p_auth, const char *psz_method ) { (void)p_access; - const char *psz_username = p_url->psz_username ?: ""; - const char *psz_password = p_url->psz_password ?: ""; + const char *psz_username = p_url->psz_username ? p_url->psz_username : ""; + const char *psz_password = p_url->psz_password ? p_url->psz_password : ""; char *psz_HA1 = NULL; char *psz_HA2 = NULL; @@ -1843,8 +1843,8 @@ static void AuthReply( access_t *p_access, const char *psz_prefix, access_sys_t *p_sys = p_access->p_sys; v_socket_t *pvs = p_sys->p_vs; - const char *psz_username = p_url->psz_username ?: ""; - const char *psz_password = p_url->psz_password ?: ""; + const char *psz_username = p_url->psz_username ? p_url->psz_username : ""; + const char *psz_password = p_url->psz_password ? p_url->psz_password : ""; if( p_auth->psz_nonce ) { @@ -1892,20 +1892,20 @@ static void AuthReply( access_t *p_access, const char *psz_prefix, psz_username, p_auth->psz_realm, p_auth->psz_nonce, - p_url->psz_path ?: "/", + p_url->psz_path ? p_url->psz_path : "/", psz_response, /* Optional parameters */ p_auth->psz_algorithm ? "algorithm=\"" : "", - p_auth->psz_algorithm ?: "", + p_auth->psz_algorithm ? p_auth->psz_algorithm : "", p_auth->psz_algorithm ? "\", " : "", p_auth->psz_cnonce ? "cnonce=\"" : "", - p_auth->psz_cnonce ?: "", + p_auth->psz_cnonce ? p_auth->psz_cnonce : "", p_auth->psz_cnonce ? "\", " : "", p_auth->psz_opaque ? "opaque=\"" : "", - p_auth->psz_opaque ?: "", + p_auth->psz_opaque ? p_auth->psz_opaque : "", p_auth->psz_opaque ? "\", " : "", p_auth->psz_qop ? "qop=\"" : "", - p_auth->psz_qop ?: "", + p_auth->psz_qop ? p_auth->psz_qop : "", p_auth->psz_qop ? "\", " : "", p_auth->i_nonce ? "nc=\"" : "uglyhack=\"", /* Will be parsed as an unhandled extension */ p_auth->i_nonce, diff --git a/modules/access/v4l2.c b/modules/access/v4l2.c index 0e9b5b6a9b..c52fa87f4f 100644 --- a/modules/access/v4l2.c +++ b/modules/access/v4l2.c @@ -2958,7 +2958,8 @@ static int ControlReset( vlc_object_t *p_obj, demux_sys_t *p_sys, int i_fd ) if( controls[i].i_cid == queryctrl.id ) break; name2var( queryctrl.name ); Control( p_obj, p_sys, i_fd, - controls[i].psz_name ? : (const char *)queryctrl.name, + controls[i].psz_name ? controls[i].psz_name + : (const char *)queryctrl.name, queryctrl.id, queryctrl.default_value ); } queryctrl.id |= V4L2_CTRL_FLAG_NEXT_CTRL; @@ -2988,7 +2989,8 @@ static int ControlReset( vlc_object_t *p_obj, demux_sys_t *p_sys, int i_fd ) if( controls[i].i_cid == queryctrl.id ) break; name2var( queryctrl.name ); Control( p_obj, p_sys, i_fd, - controls[i].psz_name ? : (const char *)queryctrl.name, + controls[i].psz_name ? controls[i].psz_name + : (const char *)queryctrl.name, queryctrl.id, queryctrl.default_value ); } } diff --git a/modules/access/vcd/cdrom.c b/modules/access/vcd/cdrom.c index 22b29de37c..a8d0f4dfea 100644 --- a/modules/access/vcd/cdrom.c +++ b/modules/access/vcd/cdrom.c @@ -1362,13 +1362,16 @@ static int CdTextParse( vlc_meta_t ***ppp_tracks, int *pi_tracks, } break; case 0x01: /* Performer */ - vlc_meta_SetArtist( p_track, psz_value ?: psz_default ); + vlc_meta_SetArtist( p_track, + psz_value ? psz_value : psz_default ); break; case 0x05: /* Messages */ - vlc_meta_SetDescription( p_track, psz_value ?: psz_default ); + vlc_meta_SetDescription( p_track, + psz_value ? psz_value : psz_default ); break; case 0x07: /* Genre */ - vlc_meta_SetGenre( p_track, psz_value ?: psz_default ); + vlc_meta_SetGenre( p_track, + psz_value ? psz_value : psz_default ); break; /* FIXME unsupported: * 0x02: songwriter diff --git a/modules/access_output/udp.c b/modules/access_output/udp.c index d9782ca423..dae64f1e47 100644 --- a/modules/access_output/udp.c +++ b/modules/access_output/udp.c @@ -175,7 +175,7 @@ static int Open( vlc_object_t *p_this ) if (psz_parser[0] == '[') psz_parser = strchr (psz_parser, ']'); - psz_parser = strchr (psz_parser ?: psz_dst_addr, ':'); + psz_parser = strchr (psz_parser ? psz_parser : psz_dst_addr, ':'); if (psz_parser != NULL) { *psz_parser++ = '\0'; diff --git a/modules/codec/subtitles/subsdec.c b/modules/codec/subtitles/subsdec.c index 5bd43a51eb..aa5ca570d6 100644 --- a/modules/codec/subtitles/subsdec.c +++ b/modules/codec/subtitles/subsdec.c @@ -269,7 +269,8 @@ static int OpenDecoder( vlc_object_t *p_this ) { psz_charset = strdup (p_dec->fmt_in.subs.psz_encoding); msg_Dbg (p_dec, "trying demuxer-specified character encoding: %s", - p_dec->fmt_in.subs.psz_encoding ?: "not specified"); + p_dec->fmt_in.subs.psz_encoding ? + p_dec->fmt_in.subs.psz_encoding : "not specified"); } /* Second, try configured encoding */ @@ -277,7 +278,7 @@ static int OpenDecoder( vlc_object_t *p_this ) { psz_charset = var_CreateGetNonEmptyString (p_dec, "subsdec-encoding"); msg_Dbg (p_dec, "trying configured character encoding: %s", - psz_charset ?: "not specified"); + psz_charset ? psz_charset : "not specified"); } /* Third, try "local" encoding with optional UTF-8 autodetection */ @@ -285,7 +286,7 @@ static int OpenDecoder( vlc_object_t *p_this ) { psz_charset = strdup (GetFallbackEncoding ()); msg_Dbg (p_dec, "trying default character encoding: %s", - psz_charset ?: "not specified"); + psz_charset ? psz_charset : "not specified"); if (var_CreateGetBool (p_dec, "subsdec-autodetect-utf8")) { diff --git a/modules/demux/ts.c b/modules/demux/ts.c index 5493c47ef8..b80031b68a 100644 --- a/modules/demux/ts.c +++ b/modules/demux/ts.c @@ -3217,7 +3217,8 @@ static void PMTSetupEsTeletext( demux_t *p_demux, ts_pid_t *pid, ts_teletext_page_t *p_dst = &p_page[i_page++]; p_dst->i_type = p_src->i_teletext_type; - p_dst->i_magazine = p_src->i_teletext_magazine_number ? : 8; + p_dst->i_magazine = p_src->i_teletext_magazine_number + ? p_src->i_teletext_magazine_number : 8; p_dst->i_page = p_src->i_teletext_page_number; memcpy( p_dst->p_iso639, p_src->i_iso6392_language_code, 3 ); } @@ -3250,7 +3251,8 @@ static void PMTSetupEsTeletext( demux_t *p_demux, ts_pid_t *pid, break; } /* FIXME check if it is the right split */ - p_dst->i_magazine = (p_src->i_composition_page_id >> 8) ? : 8; + p_dst->i_magazine = (p_src->i_composition_page_id >> 8) + ? (p_src->i_composition_page_id >> 8) : 8; p_dst->i_page = p_src->i_composition_page_id & 0xff; memcpy( p_dst->p_iso639, p_src->i_iso6392_language_code, 3 ); } diff --git a/modules/services_discovery/sap.c b/modules/services_discovery/sap.c index a43a89233c..2e1d070fcc 100644 --- a/modules/services_discovery/sap.c +++ b/modules/services_discovery/sap.c @@ -918,9 +918,11 @@ static const char *FindAttribute (const sdp_t *sdp, unsigned media, const char *name) { /* Look for media attribute, and fallback to session */ - return GetAttribute (sdp->mediav[media].pp_attributes, - sdp->mediav[media].i_attributes, name) - ?: GetAttribute (sdp->pp_attributes, sdp->i_attributes, name); + const char *attr = GetAttribute (sdp->mediav[media].pp_attributes, + sdp->mediav[media].i_attributes, name); + if (attr == NULL) + attr = GetAttribute (sdp->pp_attributes, sdp->i_attributes, name); + return attr; } diff --git a/modules/stream_out/transcode.c b/modules/stream_out/transcode.c index bc66396838..b4bf89136a 100644 --- a/modules/stream_out/transcode.c +++ b/modules/stream_out/transcode.c @@ -1492,11 +1492,15 @@ static int transcode_video_new( sout_stream_t *p_stream, sout_stream_id_t *id ) /* The dimensions will be set properly later on. * Just put sensible values so we can test an encoder is available. */ id->p_encoder->fmt_in.video.i_width = - id->p_encoder->fmt_out.video.i_width ?: - id->p_decoder->fmt_in.video.i_width ?: 16; + id->p_encoder->fmt_out.video.i_width + ? id->p_encoder->fmt_out.video.i_width + : id->p_decoder->fmt_in.video.i_width + ? id->p_decoder->fmt_in.video.i_width : 16; id->p_encoder->fmt_in.video.i_height = - id->p_encoder->fmt_out.video.i_height ?: - id->p_decoder->fmt_in.video.i_height ?: 16; + id->p_encoder->fmt_out.video.i_height + ? id->p_encoder->fmt_out.video.i_height + : id->p_decoder->fmt_in.video.i_height + ? id->p_decoder->fmt_in.video.i_height : 16; id->p_encoder->fmt_in.video.i_frame_rate = ENC_FRAMERATE; id->p_encoder->fmt_in.video.i_frame_rate_base = ENC_FRAMERATE_BASE; diff --git a/modules/video_filter/postproc.c b/modules/video_filter/postproc.c index db9e56d0e5..427e973798 100644 --- a/modules/video_filter/postproc.c +++ b/modules/video_filter/postproc.c @@ -197,7 +197,8 @@ static int OpenPostproc( vlc_object_t *p_this ) var_AddCallback( p_filter, FILTER_PREFIX "name", PPNameCallback, NULL ); if( val_orig.i_int ) { - p_sys->pp_mode = pp_get_mode_by_name_and_quality( val.psz_string?: + p_sys->pp_mode = pp_get_mode_by_name_and_quality( val.psz_string ? + val.psz_string : "default", val_orig.i_int ); @@ -328,7 +329,8 @@ static void PPChangeMode( filter_t *p_filter, const char *psz_name, vlc_mutex_lock( &p_sys->lock ); if( i_quality > 0 ) { - pp_mode_t *pp_mode = pp_get_mode_by_name_and_quality( psz_name?: + pp_mode_t *pp_mode = pp_get_mode_by_name_and_quality( psz_name ? + psz_name : "default", i_quality ); if( pp_mode ) diff --git a/modules/video_output/msw/direct3d.c b/modules/video_output/msw/direct3d.c index dcb73107bc..6435154de9 100644 --- a/modules/video_output/msw/direct3d.c +++ b/modules/video_output/msw/direct3d.c @@ -1031,7 +1031,8 @@ static int Direct3DVoutCreatePictures( vout_thread_t *p_vout, size_t i_num_pics HRESULT hr; size_t c; // if vout is already running, use current chroma, otherwise choose from upstream - int i_chroma = p_vout->output.i_chroma ? : p_vout->render.i_chroma; + int i_chroma = p_vout->output.i_chroma ? p_vout->output.i_chroma + : p_vout->render.i_chroma; I_OUTPUTPICTURES = 0; diff --git a/src/misc/filter_chain.c b/src/misc/filter_chain.c index 7061c929f2..c2b14f9f31 100644 --- a/src/misc/filter_chain.c +++ b/src/misc/filter_chain.c @@ -344,7 +344,7 @@ static filter_t *filter_chain_AppendFilterInternal( filter_chain_t *p_chain, vlc_array_append( &p_chain->filters, p_filter ); msg_Dbg( p_chain->p_this, "Filter '%s' (%p) appended to chain", - psz_name?:p_filter->psz_object_name, p_filter ); + psz_name ? psz_name : p_filter->psz_object_name, p_filter ); return p_filter; diff --git a/src/misc/variables.c b/src/misc/variables.c index 80caffffe7..1242431c22 100644 --- a/src/misc/variables.c +++ b/src/misc/variables.c @@ -68,7 +68,10 @@ static int CmpAddress( vlc_value_t v, vlc_value_t w ) { return v.p_address == w. * Local duplication functions, and local deallocation functions *****************************************************************************/ static void DupDummy( vlc_value_t *p_val ) { (void)p_val; /* unused */ } -static void DupString( vlc_value_t *p_val ) { p_val->psz_string = strdup( p_val->psz_string ?: ""); } +static void DupString( vlc_value_t *p_val ) +{ + p_val->psz_string = strdup( p_val->psz_string ? p_val->psz_string : "" ); +} static void DupList( vlc_value_t *p_val ) { @@ -1407,8 +1410,9 @@ static int InheritValue( vlc_object_t *p_this, const char *psz_name, p_var->ops->pf_dup( p_val ); /*msg_Dbg( p_this, "Inherited value for var %s from object %s", - psz_name ? : "(null)", - p_this->psz_object_name ? : "(Unknown)" );*/ + psz_name ? psz_name : "(null)", + p_this->psz_object_name + ? p_this->psz_object_name : "(Unknown)" );*/ return VLC_SUCCESS; } else if ( p_this->p_parent ) /* We are still not there */ diff --git a/src/modules/modules.c b/src/modules/modules.c index e21323488a..7c1290823b 100644 --- a/src/modules/modules.c +++ b/src/modules/modules.c @@ -292,7 +292,7 @@ const char *module_get_name( const module_t *m, bool long_name ) if( long_name && ( m->psz_longname != NULL) ) return m->psz_longname; - return m->psz_shortname ?: m->psz_object_name; + return m->psz_shortname ? m->psz_shortname : m->psz_object_name; } /** diff --git a/src/network/httpd.c b/src/network/httpd.c index 48e18a9432..7bfc071f04 100644 --- a/src/network/httpd.c +++ b/src/network/httpd.c @@ -366,7 +366,7 @@ static size_t httpd_HtmlError (char **body, int code, const char *url) "VideoLAN\n" "\n" "\n", errname, code, errname, - (url ? " (" : ""), (url ?: ""), (url ? ")" : "")); + (url ? " (" : ""), (url ? url : ""), (url ? ")" : "")); if (res == -1) { diff --git a/src/network/io.c b/src/network/io.c index 6b62d902ff..313e0e8a94 100644 --- a/src/network/io.c +++ b/src/network/io.c @@ -219,8 +219,8 @@ int *net_Listen (vlc_object_t *p_this, const char *psz_host, net_Close (fd); #if !defined(WIN32) && !defined(UNDER_CE) fd = rootwrap_bind (ptr->ai_family, socktype, - protocol ?: ptr->ai_protocol, ptr->ai_addr, - ptr->ai_addrlen); + protocol ? protocol : ptr->ai_protocol, + ptr->ai_addr, ptr->ai_addrlen); if (fd != -1) { msg_Dbg (p_this, "got socket %d from rootwrap", fd); diff --git a/src/network/tcp.c b/src/network/tcp.c index b509b66b33..0fabdd0afa 100644 --- a/src/network/tcp.c +++ b/src/network/tcp.c @@ -153,8 +153,9 @@ int __net_Connect( vlc_object_t *p_this, const char *psz_host, int i_port, for( ptr = res; ptr != NULL; ptr = ptr->ai_next ) { - int fd = net_Socket( p_this, ptr->ai_family, type ?: ptr->ai_socktype, - proto ?: ptr->ai_protocol ); + int fd = net_Socket( p_this, ptr->ai_family, + type ? type : ptr->ai_socktype, + proto ? proto : ptr->ai_protocol ); if( fd == -1 ) { msg_Dbg( p_this, "socket error: %m" ); diff --git a/src/network/udp.c b/src/network/udp.c index f063e2ffbb..f3e60981ab 100644 --- a/src/network/udp.c +++ b/src/network/udp.c @@ -151,7 +151,8 @@ static int net_ListenSingle (vlc_object_t *obj, const char *host, int port, if (host && !*host) host = NULL; - msg_Dbg (obj, "net: opening %s datagram port %d", host ?: "any", port); + msg_Dbg (obj, "net: opening %s datagram port %d", + host ? host : "any", port); int val = vlc_getaddrinfo (obj, host, port, &hints, &res); if (val) @@ -166,7 +167,7 @@ static int net_ListenSingle (vlc_object_t *obj, const char *host, int port, for (const struct addrinfo *ptr = res; ptr != NULL; ptr = ptr->ai_next) { int fd = net_Socket (obj, ptr->ai_family, ptr->ai_socktype, - protocol ?: ptr->ai_protocol); + protocol ? protocol : ptr->ai_protocol); if (fd == -1) { msg_Dbg (obj, "socket error: %m"); @@ -662,7 +663,7 @@ int __net_ConnectDgram( vlc_object_t *p_this, const char *psz_host, int i_port, { char *str; int fd = net_Socket (p_this, ptr->ai_family, ptr->ai_socktype, - proto ?: ptr->ai_protocol); + proto ? proto : ptr->ai_protocol); if (fd == -1) continue; @@ -773,7 +774,7 @@ int __net_OpenDgram( vlc_object_t *obj, const char *psz_bind, int i_bind, for (struct addrinfo *ptr = loc; ptr != NULL; ptr = ptr->ai_next) { int fd = net_Socket (obj, ptr->ai_family, ptr->ai_socktype, - protocol ?: ptr->ai_protocol); + protocol ? protocol : ptr->ai_protocol); if (fd == -1) continue; // usually, address family not supported diff --git a/src/video_output/video_output.c b/src/video_output/video_output.c index 5308c6a77f..3c932f6985 100644 --- a/src/video_output/video_output.c +++ b/src/video_output/video_output.c @@ -1927,7 +1927,8 @@ static int DeinterlaceCallback( vlc_object_t *p_this, char const *psz_cmd, const deinterlace_mode_t *p_mode; for( p_mode = &p_deinterlace_mode[0]; p_mode->psz_mode; p_mode++ ) { - if( !strcmp( p_mode->psz_mode, newval.psz_string ?: "" ) ) + if( !strcmp( p_mode->psz_mode, + newval.psz_string ? newval.psz_string : "" ) ) break; } if( !p_mode->psz_mode ) @@ -2023,7 +2024,7 @@ static void DeinterlaceEnable( vout_thread_t *p_vout ) else if( DeinterlaceIsPresent( p_vout, false ) ) psz_mode = var_CreateGetNonEmptyString( p_vout, "sout-deinterlace-mode" ); } - var_SetString( p_vout, "deinterlace", psz_mode ?: "" ); + var_SetString( p_vout, "deinterlace", psz_mode ? psz_mode : "" ); free( psz_mode ); } -- 2.39.2