diff options
author | 諏訪子 <suwako@076.moe> | 2024-06-22 00:24:24 +0900 |
---|---|---|
committer | 諏訪子 <suwako@076.moe> | 2024-06-22 00:24:49 +0900 |
commit | eaccc846f6d7ebb5f38b39909e854febbe572340 (patch) | |
tree | a5653c3d37bb49ff99f737f5f2df6441be5e110c /src | |
parent | f3a6d1bfe0ae01364d71409f1ec3039e9ebb73d1 (diff) |
Linux: segfaultの修正
Diffstat (limited to 'src')
-rw-r--r-- | src/storage.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/storage.c b/src/storage.c index b43529e..1924acf 100644 --- a/src/storage.c +++ b/src/storage.c @@ -16,8 +16,9 @@ const char *display_storage() { "internal error: failed to initialize ZFS library", strlen("internal error: failed to initialize ZFS library") ) == 0 || - strncmp(iszfs, "sh: zpool: not found", strlen("sh: zpool: not found") - ) == 0) { + strncmp(iszfs, "sh: zpool: not found", strlen("sh: zpool: not found")) == 0 || + strncmp(iszfs, "sh: 1: zpool: not found", strlen("sh: 1: zpool: not found")) == 0 + ) { return run_command_s("df -h | " "awk '/^\\/dev\\// {printf \"%s: %s / %s, \", $1, $3, $2}' | " "awk '{sub(/, $/, \"\"); print}'"); |