summaryrefslogtreecommitdiffstats
path: root/src/gprs.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gprs.c')
-rw-r--r--src/gprs.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gprs.c b/src/gprs.c
index 6b88fcbb..7c316793 100644
--- a/src/gprs.c
+++ b/src/gprs.c
@@ -603,12 +603,12 @@ static DBusMessage *pri_set_property(DBusConnection *conn,
if (ctx->active == (ofono_bool_t) value)
return dbus_message_new_method_return(msg);
+ if (value && !ctx->gprs->attached)
+ return __ofono_error_not_attached(msg);
+
if (ctx->gprs->flags & GPRS_FLAG_ATTACHING)
return __ofono_error_busy(msg);
- if (value && !ctx->gprs->attached)
- return __ofono_error_failed(msg);
-
if (gc == NULL || gc->driver->activate_primary == NULL ||
gc->driver->deactivate_primary == NULL)
return __ofono_error_not_implemented(msg);