Il sito funziona meglio con JavaScript.
Home
Esplora
Aiuto
Accedi
rinri
/
slstatus
Segui
1
Vota
0
Forka
0
Codice
Problemi
0
Pull Requests
0
Rilasci
0
Wiki
Attività
Sfoglia il codice sorgente
swap_perc: check for division by zero
master
Aaron Marcher
6 anni fa
parent
d8ce4e6942
commit
806815778f
1 ha cambiato i file
con
4 aggiunte
e
0 eliminazioni
Visualizzazione separata
Opzioni Diff
Mostra statistiche
Scarica il file Patch
Scarica il file Diff
+4
-0
components/swap.c
+ 4
- 0
components/swap.c
Vedi File
@@ -76,6 +76,10 @@
}
sscanf(match, "SwapFree: %ld kB\n", &free);
if (total == 0) {
return NULL;
}
return bprintf("%d%%", 100 * (total - free - cached) / total);
}
Scrivi
Anteprima
Caricamento…
Annulla
Salva