[MPlayer-dev-eng] Fix for warnings
D Richard Felker III
dalias at aerifal.cx
Sun Feb 24 17:01:07 CET 2002
this is probably not the correct fix. using another pointer type where
void is expected should not alone generate a warning. apparently these
pointers have some other qualifier that's an issue (volatile), and it
might be a good idea to look at why they do and whether they need
it... at a glance, i see no reason why these should be volatile; it
looks like it would just slow things down a good bit. maybe to work
around a bug in a broken compiler version??
rich
On Sun, Feb 24, 2002 at 04:40:11PM +0100, Daniel Egger wrote:
> Hija,
>
> here's a fix for this:
>
> In file included from mplayer.c:401:
> cfg-mplayer.h:105: warning: initialization discards qualifiers from
> pointer target type
> cfg-mplayer.h:106: warning: initialization discards qualifiers from
> pointer target type
> cfg-mplayer.h:107: warning: initialization discards qualifiers from
> pointer target type
> cfg-mplayer.h:108: warning: initialization discards qualifiers from
> pointer target type
>
> --
> Servus,
> Daniel
> Index: cfg-mplayer.h
> ===================================================================
> RCS file: /cvsroot/mplayer/main/cfg-mplayer.h,v
> retrieving revision 1.134
> diff -u -r1.134 cfg-mplayer.h
> --- cfg-mplayer.h 21 Feb 2002 16:02:26 -0000 1.134
> +++ cfg-mplayer.h 24 Feb 2002 15:52:39 -0000
> @@ -102,10 +102,10 @@
>
> /* Options related to audio out plugins */
> struct config ao_plugin_conf[]={
> - {"list", &ao_plugin_cfg.plugin_list, CONF_TYPE_STRING, 0, 0, 0, NULL},
> - {"delay", &ao_plugin_cfg.pl_delay_len, CONF_TYPE_INT, CONF_MIN, 0, 0, NULL},
> - {"format", &ao_plugin_cfg.pl_format_type, CONF_TYPE_INT, CONF_MIN, 0, 0, NULL},
> - {"fout", &ao_plugin_cfg.pl_resample_fout, CONF_TYPE_INT, CONF_MIN, 0, 0, NULL},
> + {"list", (void *) &ao_plugin_cfg.plugin_list, CONF_TYPE_STRING, 0, 0, 0, NULL},
> + {"delay", (void *) &ao_plugin_cfg.pl_delay_len, CONF_TYPE_INT, CONF_MIN, 0, 0, NULL},
> + {"format", (void *) &ao_plugin_cfg.pl_format_type, CONF_TYPE_INT, CONF_MIN, 0, 0, NULL},
> + {"fout", (void *) &ao_plugin_cfg.pl_resample_fout, CONF_TYPE_INT, CONF_MIN, 0, 0, NULL},
> {NULL, NULL, 0, 0, 0, 0, NULL}
> };
>
More information about the MPlayer-dev-eng
mailing list