On Fri, Oct 12, 2018 at 03:41:53PM +0800, Su Yanjun wrote:
> When using gcc8 to compile btrfs-progs, it complains as below:
>
> ctree.c: In function 'btrfs_search_slot_for_read':
> ctree.c:1249:45: warning: passing argument 3 of 'btrfs_search_slot'
> discards 'const' qualifier from pointer
On Fri, Oct 12, 2018 at 09:36:37AM +0800, Su Yanjun wrote:
> When using gcc8 compiles utils.c, it complains as below:
>
> utils.c:852:45: warning: '%s' directive output may be truncated writing
> up to 4095 bytes into a region of size 4084 [-Wformat-truncation=]
>snprintf(path, sizeof(path), "
When using gcc8 to compile btrfs-progs, it complains as below:
ctree.c: In function 'btrfs_search_slot_for_read':
ctree.c:1249:45: warning: passing argument 3 of 'btrfs_search_slot'
discards 'const' qualifier from pointer target type
[-Wdiscarded-qualifiers]
ret = btrfs_se
When using gcc8 compiles utils.c, it complains as below:
utils.c:852:45: warning: '%s' directive output may be truncated writing
up to 4095 bytes into a region of size 4084 [-Wformat-truncation=]
snprintf(path, sizeof(path), "/dev/mapper/%s", name);