diff options
author | TingPing <tingping@tingping.se> | 2015-02-21 21:01:14 -0500 |
---|---|---|
committer | TingPing <tingping@tingping.se> | 2015-02-21 21:01:14 -0500 |
commit | 7e7e87600e4a8e826e39ced94432582007a8ee0a (patch) | |
tree | f75b0b6adee7c23e5bdc0b6f1ae32ac55ffa1746 /plugins/sysinfo/unix | |
parent | c36d4859d7e8d8907e4fe82e82d690d76df389ab (diff) |
More type issues/warnings
Diffstat (limited to 'plugins/sysinfo/unix')
-rw-r--r-- | plugins/sysinfo/unix/parse.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/sysinfo/unix/parse.c b/plugins/sysinfo/unix/parse.c index 0ca140de..f41f89a7 100644 --- a/plugins/sysinfo/unix/parse.c +++ b/plugins/sysinfo/unix/parse.c @@ -116,7 +116,7 @@ gint64 xs_parse_uptime(void) return 0; if(fgets(buffer, bsize, fp) != NULL) - uptime = strtol(buffer, NULL, 0); + uptime = g_ascii_strtoll(buffer, NULL, 0); fclose(fp); @@ -146,13 +146,13 @@ int xs_parse_sound(char *snd_card) if(isdigit(buffer[0]) || isdigit(buffer[1])) { char card_buf[bsize]; - long card_id = 0; + gint64 card_id = 0; pos = strstr(buffer, ":"); - card_id = strtoll(buffer, NULL, 0); + card_id = g_ascii_strtoll(buffer, NULL, 0); if (card_id == 0) g_snprintf(card_buf, bsize, "%s", pos+2); else - g_snprintf(card_buf, bsize, "%ld: %s", card_id, pos+2); + g_snprintf(card_buf, bsize, "%"G_GINT64_FORMAT": %s", card_id, pos+2); pos = strstr(card_buf, "\n"); *pos = '\0'; strcat(cards, card_buf); |