在OpenSUSE 11.4上编译,会报以下错误很多次
../redis-nginx-module-0.3.6/ngx_http_redis_module.c:500:24: warning: array index of '3' indexes past the end of an array (that contains 2 elements) [-Warray-bounds]
if (ngx_strncmp(p, "$", sizeof("$") - 1) == 0) {
~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~
src/core/ngx_string.h:53:75: note: expanded from:
#define ngx_strncmp(s1, s2, n) strncmp((const char *) s1, (const char *) s2, n)
^
/usr/include/bits/string2.h:926:19: note: expanded from:
? strcmp (s1, s2) : strncmp (s1, s2, n)))
^
/usr/include/bits/string2.h:817:28: note: expanded from:
: __strcmp_gc (s1, s2, __s2_len)) \
^
/usr/include/bits/string2.h:911:27: note: expanded from:
(__const char *) (s2))[3]); \
^ ~
只要是用到了ngx_strncmp地方,都报警告
在 2012年6月25日 下午12:46,agentzh
<age...@gmail.com>写道:
Hello!
On Mon, Jun 25, 2012 at 12:40 PM, Wendal Chen <wend...@gmail.com> wrote:
> Good!
>
> 如果升级,需要注意些神马吗?
>
注意总是先在测试环境运行自己的业务测试集就可以了 :) 虽然向后兼容性是我一直在努力保证的,但升级前自己进行必要的回归测试还是必要的 :)
Regards,
--
Wendal Chen
GuangDong China