[wiki] [sites] Correct the return type of getbattery || Theo Le Ninivin

From: <git_AT_suckless.org>
Date: Thu, 31 Dec 2015 12:36:47 +0100

commit fce6a66354f0ac5fa2c54374a0a927f792e107fa
Author: Theo Le Ninivin <theo.leninivin_AT_kaufda.de>
Date: Thu Dec 31 12:36:05 2015 +0100

    Correct the return type of getbattery
    
    Additionally corrected a few whitespace inconsistencies.

diff --git a/dwm.suckless.org/dwmstatus/profil-dwmstatus-1.0.c b/dwm.suckless.org/dwmstatus/profil-dwmstatus-1.0.c
index 1d619c3..e016f2c 100644
--- a/dwm.suckless.org/dwmstatus/profil-dwmstatus-1.0.c
+++ b/dwm.suckless.org/dwmstatus/profil-dwmstatus-1.0.c
_AT_@ -18,7 +18,7 @@ void setstatus(char *str) {
 
 float getfreq(char *file) {
         FILE *fd;
- char *freq;
+ char *freq;
         float ret;
 
         freq = malloc(10);
_AT_@ -55,11 +55,11 @@ char *getdatetime() {
                 fprintf(stderr, "strftime is 0.
");
                 exit(1);
         }
-
+
         return buf;
 }
 
-int getbattery() {
+float getbattery() {
         FILE *fd;
         int energy_now, energy_full, voltage_now;
 
_AT_@ -107,7 +107,7 @@ int main(void) {
 
         if((status = malloc(200)) == NULL)
                 exit(1);
-
+
 
         for (;;sleep(1)) {
                 cpu0 = getfreq("/sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq");
Received on Thu Dec 31 2015 - 12:36:47 CET

This archive was generated by hypermail 2.3.0 : Thu Dec 31 2015 - 12:48:12 CET