mirror of
https://bitbucket.org/King_DuckZ/keepupnpup.git
synced 2024-11-07 21:29:00 +00:00
Don't throw if list ends and delete urls properly.
This commit is contained in:
parent
6b7fd47745
commit
88d891a448
1 changed files with 2 additions and 1 deletions
|
@ -56,6 +56,7 @@ namespace kuu {
|
||||||
|
|
||||||
operator struct UPNPUrls* () { return &urls; }
|
operator struct UPNPUrls* () { return &urls; }
|
||||||
UPNPUrlsWithInitFlag* operator-> () { return this; }
|
UPNPUrlsWithInitFlag* operator-> () { return this; }
|
||||||
|
bool operator not() const { return not initialized; }
|
||||||
};
|
};
|
||||||
|
|
||||||
//see: http://stackoverflow.com/questions/24611215/one-liner-for-raii-on-non-pointer
|
//see: http://stackoverflow.com/questions/24611215/one-liner-for-raii-on-non-pointer
|
||||||
|
@ -280,7 +281,7 @@ namespace kuu {
|
||||||
|
|
||||||
retval.push_back(redir);
|
retval.push_back(redir);
|
||||||
}
|
}
|
||||||
else {
|
else if (713 != r) {
|
||||||
throw UPNPException(r, "Error in invocation of UPNP_GetGenericPortMappingEntry()", strupnperror(r));
|
throw UPNPException(r, "Error in invocation of UPNP_GetGenericPortMappingEntry()", strupnperror(r));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue