cli: fix build on 32-bit platforms

This commit is contained in:
Dan Williams
2010-05-05 04:54:03 -07:00
parent 688de6d782
commit 14bfae6802
2 changed files with 3 additions and 3 deletions

View File

@@ -373,7 +373,7 @@ show_connection (NMConnection *data, gpointer user_data)
if (s_con) { if (s_con) {
/* Obtain field values */ /* Obtain field values */
timestamp = nm_setting_connection_get_timestamp (s_con); timestamp = nm_setting_connection_get_timestamp (s_con);
timestamp_str = g_strdup_printf ("%ld", timestamp); timestamp_str = g_strdup_printf ("%" G_GUINT64_FORMAT, timestamp);
strftime (timestamp_real_str, sizeof (timestamp_real_str), "%c", localtime ((time_t *) &timestamp)); strftime (timestamp_real_str, sizeof (timestamp_real_str), "%c", localtime ((time_t *) &timestamp));
nmc->allowed_fields[0].value = nm_setting_connection_get_id (s_con); nmc->allowed_fields[0].value = nm_setting_connection_get_id (s_con);
nmc->allowed_fields[1].value = nm_setting_connection_get_uuid (s_con); nmc->allowed_fields[1].value = nm_setting_connection_get_uuid (s_con);

View File

@@ -495,7 +495,7 @@ setting_connection_details (NMSetting *setting, NmCli *nmc)
print_fields (nmc->print_fields, nmc->allowed_fields); /* Print field names */ print_fields (nmc->print_fields, nmc->allowed_fields); /* Print field names */
timestamp = nm_setting_connection_get_timestamp (s_con); timestamp = nm_setting_connection_get_timestamp (s_con);
timestamp_str = g_strdup_printf ("%ld", timestamp); timestamp_str = g_strdup_printf ("%" G_GUINT64_FORMAT, timestamp);
nmc->allowed_fields[0].value = NM_SETTING_CONNECTION_SETTING_NAME; nmc->allowed_fields[0].value = NM_SETTING_CONNECTION_SETTING_NAME;
nmc->allowed_fields[1].value = nm_setting_connection_get_id (s_con); nmc->allowed_fields[1].value = nm_setting_connection_get_id (s_con);
@@ -1075,7 +1075,7 @@ setting_serial_details (NMSetting *setting, NmCli *nmc)
bits_str = g_strdup_printf ("%d", nm_setting_serial_get_bits (s_serial)); bits_str = g_strdup_printf ("%d", nm_setting_serial_get_bits (s_serial));
parity_str = g_strdup_printf ("%c", nm_setting_serial_get_parity (s_serial)); parity_str = g_strdup_printf ("%c", nm_setting_serial_get_parity (s_serial));
stopbits_str = g_strdup_printf ("%d", nm_setting_serial_get_stopbits (s_serial)); stopbits_str = g_strdup_printf ("%d", nm_setting_serial_get_stopbits (s_serial));
send_delay_str = g_strdup_printf ("%ld", nm_setting_serial_get_send_delay (s_serial)); send_delay_str = g_strdup_printf ("%" G_GUINT64_FORMAT, nm_setting_serial_get_send_delay (s_serial));
nmc->allowed_fields[0].value = NM_SETTING_SERIAL_SETTING_NAME; nmc->allowed_fields[0].value = NM_SETTING_SERIAL_SETTING_NAME;
nmc->allowed_fields[1].value = baud_str; nmc->allowed_fields[1].value = baud_str;