[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] Fix most warnings with gcc 4.4 on Linux
From: |
Andrei Kholodnyi |
Subject: |
[PATCH] Fix most warnings with gcc 4.4 on Linux |
Date: |
Wed, 8 Sep 2010 11:23:08 +0200 |
> + if ((revents = id->alsa_poll_fds[count-1].revents)){
revents = id->alsa_poll_fds[count-1].revents;
if(0 != revent)
> + ? ?const bool action_is_open = strcmp (action, "--open") == 0;
why you are using bool here? it is not a C standard. would it be
possible to use int? or gboolean
> +/*
> ?static void cicero_set_pitch(signed int pitch);
> ?static void cicero_set_volume(signed int pitch);
> ?static void cicero_set_voice(EVoiceType voice);
> +*/
if these are not used, just remove them
> +/*
> ?static void
> ?cicero_set_pitch(signed int pitch)
> ?{
> @@ -475,5 +477,6 @@ static void
> ?cicero_set_voice(EVoiceType voice)
> ?{
> ?}
> +*/
the same here
> + ? ? ? DBG("Espeak: Requested data: |%s| %d %ld", data, msgtype, (long)
> bytes);
why you cast here? just change to %d
> + ? ?DBG("Cache: cleaning, cache size %ld kbytes (>max %d).", (long)
> (FestivalCache.size/1024),
same
> +static const struct option spd_long_options_[] = {
> + ? ?{"run-daemon", 0, 0, 'd'},
> + ? ?{"run-single", 0, 0, 's'},
> + ? ?{"spawn", 0, 0, 'a'},
> + ? ?{"log-level", 1, 0, 'l'},
> + ? ?{"communication-method", 1, 0, 'c'},
> + ? ?{"socket-path", 1, 0, 'S'},
> + ? ?{"port", 1, 0, 'p'},
> + ? ?{"pid-file", 1, 0, 'P'},
> + ? ?{"config-file", 1, 0, 'C'},
> + ? ?{"version", 0, 0, 'v'},
> + ? ?{"debug", 0, 0, 'D'},
> + ? ?{"help", 0, 0, 'h'},
> + ? ?{0, 0, 0, 0}
> +};
> +const struct option *const spd_long_options = spd_long_options_;
this i didn't get. why you are not using structure directly, but
introducing pointer to it instead?
> +const char *const spd_short_options = "dsal:c:S:p:P:C:vDh";
should it be static?
> +#define _GNU_SOURCE
this shall be defined via -D in Makefile
> + ? ? ? ? ? ? ? char buf[1];
char buf;
[PATCH] Fix most warnings with gcc 4.4 on Linux, Christopher Brannon, 2010/09/07
[PATCH] Fix most warnings with gcc 4.4 on Linux,
Andrei Kholodnyi <=