mirror of
https://github.com/status-im/miniupnp.git
synced 2025-01-19 02:41:25 +00:00
upnpsoap.c: ExecuteSoapAction() use memchr() instead of strchr()
This commit is contained in:
parent
a5fd382e95
commit
84cd9e6289
@ -2350,8 +2350,8 @@ ExecuteSoapAction(struct upnphttp * h, const char * action, int n)
|
||||
|
||||
/* SoapAction example :
|
||||
* urn:schemas-upnp-org:service:WANIPConnection:1#GetStatusInfo */
|
||||
p = strchr(action, '#');
|
||||
if(p && (p - action) < n) {
|
||||
p = memchr(action, '#', n);
|
||||
if(p) {
|
||||
for(i = 0; i < ((int)sizeof(namespace) - 1) && (action + i) < p; i++)
|
||||
namespace[i] = action[i];
|
||||
namespace[i] = '\0';
|
||||
|
Loading…
x
Reference in New Issue
Block a user