network: Don't try to show a wizard that failed to setup
This fixes a critical warning when mobile-broadband-provider-info isn't installed into the correct prefix.
This commit is contained in:
parent
fd059a2d14
commit
59b7500fb6
1 changed files with 8 additions and 0 deletions
|
@ -485,9 +485,17 @@ cc_network_panel_connect_to_3g_network (CcNetworkPanel *panel,
|
||||||
if (caps & NM_DEVICE_MODEM_CAPABILITY_GSM_UMTS) {
|
if (caps & NM_DEVICE_MODEM_CAPABILITY_GSM_UMTS) {
|
||||||
wizard = nma_mobile_wizard_new (GTK_WINDOW (toplevel), NULL, NM_DEVICE_MODEM_CAPABILITY_GSM_UMTS, FALSE,
|
wizard = nma_mobile_wizard_new (GTK_WINDOW (toplevel), NULL, NM_DEVICE_MODEM_CAPABILITY_GSM_UMTS, FALSE,
|
||||||
gsm_mobile_wizard_done, closure);
|
gsm_mobile_wizard_done, closure);
|
||||||
|
if (wizard == NULL) {
|
||||||
|
g_warning ("failed to construct GSM wizard");
|
||||||
|
return;
|
||||||
|
}
|
||||||
} else if (caps & NM_DEVICE_MODEM_CAPABILITY_CDMA_EVDO) {
|
} else if (caps & NM_DEVICE_MODEM_CAPABILITY_CDMA_EVDO) {
|
||||||
wizard = nma_mobile_wizard_new (GTK_WINDOW (toplevel), NULL, NM_DEVICE_MODEM_CAPABILITY_CDMA_EVDO, FALSE,
|
wizard = nma_mobile_wizard_new (GTK_WINDOW (toplevel), NULL, NM_DEVICE_MODEM_CAPABILITY_CDMA_EVDO, FALSE,
|
||||||
cdma_mobile_wizard_done, closure);
|
cdma_mobile_wizard_done, closure);
|
||||||
|
if (wizard == NULL) {
|
||||||
|
g_warning ("failed to construct CDMA wizard");
|
||||||
|
return;
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
g_warning ("Network panel loaded with connect-3g but the selected device"
|
g_warning ("Network panel loaded with connect-3g but the selected device"
|
||||||
" does not support GSM or CDMA");
|
" does not support GSM or CDMA");
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue