qmicli,dms: avoid shadowing global 'timezone' variable

qmicli-dms.c: In function ‘get_time_ready’:
    qmicli-dms.c:1585: error: declaration of ‘timezone’ shadows a global declaration
    /usr/include/time.h:292: error: shadowed declaration is here
    make[4]: *** [qmicli-qmicli-dms.o] Error 1
    make[4]: Leaving directory `/usr/src/libqmi-1.13.4/src/qmicli'
    make[3]: *** [all-recursive] Error 1
    make[3]: Leaving directory `/usr/src/libqmi-1.13.4/src/qmicli'
    make[2]: *** [all-recursive] Error 1
    make[2]: Leaving directory `/usr/src/libqmi-1.13.4/src'
    make[1]: *** [all-recursive] Error 1
    make[1]: Leaving directory `/usr/src/libqmi-1.13.4'
    make: *** [all] Error 2
This commit is contained in:
Aleksander Morgado 2015-02-24 01:26:06 +01:00
parent f8ccc6b973
commit 656b5d17d9
1 changed files with 4 additions and 4 deletions

View File

@ -1582,7 +1582,7 @@ get_time_ready (QmiClientDms *client,
QmiDmsTimeSource time_source;
GError *error = NULL;
gchar *str;
GTimeZone *timezone;
GTimeZone *time_zone;
GDateTime *gpstime_epoch;
GDateTime *computed_epoch;
@ -1609,8 +1609,8 @@ get_time_ready (QmiClientDms *client,
NULL);
/* January 6th 1980 */
timezone = g_time_zone_new_utc ();
gpstime_epoch = g_date_time_new (timezone, 1980, 1, 6, 0, 0, 0.0);
time_zone = g_time_zone_new_utc ();
gpstime_epoch = g_date_time_new (time_zone, 1980, 1, 6, 0, 0, 0.0);
computed_epoch = g_date_time_add_seconds (gpstime_epoch, ((gdouble) time_count / 1000.0));
str = g_date_time_format (computed_epoch, "%F %T");
@ -1648,7 +1648,7 @@ get_time_ready (QmiClientDms *client,
}
g_date_time_unref (gpstime_epoch);
g_time_zone_unref (timezone);
g_time_zone_unref (time_zone);
qmi_message_dms_get_time_output_unref (output);
shutdown (TRUE);