mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-01 23:03:54 -06:00
net: Move error reporting from net_init_client/netdev to the calling site
It looks strange that net_init_client() and net_init_netdev() both take an "Error **errp" parameter, but then do the error reporting with "error_report_err(local_err)" on their own. Let's move the error reporting to the calling site instead to simplify this code a little bit. Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
This commit is contained in:
parent
136c67e078
commit
34f708b0b6
3 changed files with 8 additions and 26 deletions
|
@ -206,7 +206,7 @@ extern const char *legacy_bootp_filename;
|
|||
|
||||
int net_client_init(QemuOpts *opts, bool is_netdev, Error **errp);
|
||||
int net_client_parse(QemuOptsList *opts_list, const char *str);
|
||||
int net_init_clients(void);
|
||||
int net_init_clients(Error **errp);
|
||||
void net_check_clients(void);
|
||||
void net_cleanup(void);
|
||||
void hmp_host_net_add(Monitor *mon, const QDict *qdict);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue