Commit 45ec6c6
nvme: fix compilation error
gcc 7.4.0.
nvme.c: In function ‘print_relatives’:
nvme.c:3505:3: error: ignoring return value of ‘asprintf’, declared with attribute warn_unused_result [-Werror=unused-result]
asprintf(&path, "/sys/class/nvme/%s", devicename);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
nvme.c:3509:3: error: ignoring return value of ‘asprintf’, declared with attribute warn_unused_result [-Werror=unused-result]
asprintf(&path, "/sys/block/%s/device", devicename);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
Makefile:57: recipe for target 'nvme' failed
make: *** [nvme] Error 1
Signed-off-by: Sagi Grimberg <[email protected]>1 parent d01d6a8 commit 45ec6c6
1 file changed
Lines changed: 10 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3502 | 3502 | | |
3503 | 3503 | | |
3504 | 3504 | | |
3505 | | - | |
| 3505 | + | |
| 3506 | + | |
| 3507 | + | |
| 3508 | + | |
| 3509 | + | |
3506 | 3510 | | |
3507 | 3511 | | |
3508 | 3512 | | |
3509 | | - | |
| 3513 | + | |
| 3514 | + | |
| 3515 | + | |
| 3516 | + | |
| 3517 | + | |
3510 | 3518 | | |
3511 | 3519 | | |
3512 | 3520 | | |
| |||
0 commit comments