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

Commit 3e1ffdb2 authored by David Christie's avatar David Christie
Browse files

Update GeofenceHardwareRequestParcelable to match parcel/unparcel format.

Test: manual
Bug: 216631962

Change-Id: I3d6d1be9d6c312fe0bf98f600ff8fc9c617f8ec3
parent 1adea76f
Loading
Loading
Loading
Loading
+3 −6
Original line number Diff line number Diff line
@@ -16,9 +16,9 @@

package android.hardware.location;

import android.os.BadParcelableException;
import android.os.Parcel;
import android.os.Parcelable;
import android.util.Log;

/**
 * Geofence Hardware Request used for internal location services communication.
@@ -140,10 +140,7 @@ public final class GeofenceHardwareRequestParcelable implements Parcelable {
        public GeofenceHardwareRequestParcelable createFromParcel(Parcel parcel) {
            int geofenceType = parcel.readInt();
            if (geofenceType != GeofenceHardwareRequest.GEOFENCE_TYPE_CIRCLE) {
                Log.e(
                        "GeofenceHardwareRequest",
                        String.format("Invalid Geofence type: %d", geofenceType));
                return null;
                throw new BadParcelableException("Invalid Geofence type: " + geofenceType);
            }

            GeofenceHardwareRequest request = GeofenceHardwareRequest.createCircularGeofence(