net: wget: make wget_with_dns return value compatible with its lwip version

There are two wget_with_dns functions, one in the legacy network
stack and one in lwip, but the return values are not compatible.
This commit modifies the legacy version of wget_with_dns so that
the return values are compatible: 0 on success, otherwise a negative
error. This way wget_with_dns can be called in a network stack
agnostic way.

Signed-off-by: Adriano Cordova <adrianox@gmail.com>
3 files changed