[dm-devel] [PATCH] libmultipath: fix compile error with glibc-2.34+
Martin Wilck
mwilck at suse.com
Thu Aug 12 11:17:00 UTC 2021
Hello Lixiaokeng,
On Mi, 2021-08-11 at 21:11 +0800, lixiaokeng wrote:
> There is an error when complie with glibc-2.34:
> comparison of integer expressions of different signedness:
> 'size_t' {aka 'long unsigned int'} and 'long int'
> [-Werror=sign-compare]
>
> The reason is that PTHREAD_STACK_MIN may be defined
> long int which is signed in glibc-2.34+. Explicitly assign
> it to the size_t variable to fix it.
>
> Signed-off-by: Lixiaokeng <lixiaokeng at huawei.com>
> Signed-off-by: Zhiqiang Liu <liuzhiqiang26 at huawei.com>
Thanks! Ben had already submitted a patch for this in
https://listman.redhat.com/archives/dm-devel/2021-July/msg00159.html.
Ben's patch handles the error case (-1) more correctly.
Regards
Martin
More information about the dm-devel
mailing list