legacy-net: wget: fix wget_info handling after new tcp legacy stack
authorAdriano Cordova <adrianox@gmail.com>
Mon, 3 Mar 2025 14:13:10 +0000 (11:13 -0300)
committerHeinrich Schuchardt <heinrich.schuchardt@canonical.com>
Mon, 10 Mar 2025 05:41:01 +0000 (06:41 +0100)
commit908033ea22605615c3a033408d5c3ceb6446b09a
tree66eb22ed723bcabf5a8627097fc69e0857cf5d0c
parent2eda179568771241c1c9fb09d6644a560fb8dcfc
legacy-net: wget: fix wget_info handling after new tcp legacy stack

Check wget_info->buffer_size for overflow and do not clean the wget_info struct
on failure, let the owner of the struct handle the error. The latter is necesary
, e.g., for when a request fails because the provided buffer was too small.

Signed-off-by: Adriano Cordova <adriano.cordova@canonical.com>
net/wget.c