Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9c50996b authored by Irfan Sheriff's avatar Irfan Sheriff Committed by Android (Google) Code Review
Browse files

Merge "Dont start wifi if in airplane mode" into froyo

parents a77acab9 60e3ba07
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -263,10 +263,13 @@ public class WifiService extends IWifiManager.Stub {
    /**
     * Check if Wi-Fi needs to be enabled and start
     * if needed
     *
     * This function is used only at boot time
     */
    public void startWifi() {
        /* Start if Wi-Fi is enabled or the saved state indicates Wi-Fi was on */
        boolean wifiEnabled = getPersistedWifiEnabled() || testAndClearWifiSavedState();
        boolean wifiEnabled = !isAirplaneModeOn()
                && (getPersistedWifiEnabled() || testAndClearWifiSavedState());
        Slog.i(TAG, "WifiService starting up with Wi-Fi " +
                (wifiEnabled ? "enabled" : "disabled"));
        setWifiEnabled(wifiEnabled);