我正在尝试使用来自火柴的fnmatch.h函数
printf("match: %i") ,fnmatch("hello", "hello world", 0);
上面打印的负数很大。电话应该是什么样子的?
发布于 2016-04-21 00:14:08
你不小心用了C的逗号操作符。我认为您希望将fnmatch的返回值传递给printf,因此应该将该行更改为:
printf("match: %i", fnmatch("hello", "hello world", 0));https://stackoverflow.com/questions/36757379
复制相似问题