coverity 177526: pointer difference already scaled

This commit is contained in:
Andy Green 2017-03-08 14:10:31 +08:00
parent 3a09c3b7d6
commit 2f3b4c8f96

View file

@ -190,8 +190,7 @@ lws_extension_server_handshake(struct lws *wsi, char **p, int budget)
!strncmp(args, po->name,
strlen(po->name))) {
oa.option_name = NULL;
oa.option_index = (po - opts) /
sizeof(*po);
oa.option_index = po - opts;
oa.start = NULL;
lwsl_debug("setting %s\n", po->name);
if (!ext->callback(