ソースを参照

simplified wifi_essid by removing one malloc()

master
Aaron Marcher 8年前
committed by Aaron Marcher (drkhsh)
コミット
85db24fef0
1個のファイルの変更1行の追加5行の削除
  1. +1
    -5
      slstatus.c

+ 1
- 5
slstatus.c ファイルの表示

@@ -672,11 +672,7 @@ wifi_perc(const char *wificard)
char *
wifi_essid(const char *wificard)
{
char *id = malloc(IW_ESSID_MAX_SIZE+1);
if (id == NULL) {
fprintf(stderr, "Cannot get ESSID.");
return smprintf("n/a");
}
char id[IW_ESSID_MAX_SIZE+1];
int sockfd;
struct iwreq wreq;



読み込み中…
キャンセル
保存