While compiling using gcc 7.1.1 I ran into compile errors, eg.
nvme.c: In function ‘scan_dev_filter.part.5’:
nvme.c:797:35: error: ‘%s’ directive output may be truncated writing " \
"up to 255 bytes into a region of size 251 [-Werror=format-truncation=]
snprintf(path, sizeof(path), "%s%s", dev, d->d_name);
This is caused because the buffer on the stack is only 256 bytes and the
dirent.d_name is 256 and the constant string is "/dev/", so 256 + 5,
but I've rounded up to nearest 4/8 byte alignment of 264.