* [PATCH] gprs: Fix release cid in gprs_deactive_for_remove
@ 2010-08-09 9:28 Zhenhua Zhang
2010-08-09 14:11 ` Denis Kenzior
0 siblings, 1 reply; 2+ messages in thread
From: Zhenhua Zhang @ 2010-08-09 9:28 UTC (permalink / raw)
To: ofono
[-- Attachment #1: Type: text/plain, Size: 648 bytes --]
Similiar to pri_deactive_callback, we should release the context id in
gprs_deactive_for_remove() as well.
---
src/gprs.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/src/gprs.c b/src/gprs.c
index 8d807dd..2c5bb4e 100644
--- a/src/gprs.c
+++ b/src/gprs.c
@@ -1262,6 +1262,9 @@ static void gprs_deactivate_for_remove(const struct ofono_error *error,
return;
}
+ gprs_cid_release(gprs, ctx->context.cid);
+ ctx->context.cid = 0;
+
if (gprs->settings) {
g_key_file_remove_group(gprs->settings, ctx->key, NULL);
storage_sync(gprs->imsi, SETTINGS_STORE, gprs->settings);
--
1.7.0.4
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH] gprs: Fix release cid in gprs_deactive_for_remove
2010-08-09 9:28 [PATCH] gprs: Fix release cid in gprs_deactive_for_remove Zhenhua Zhang
@ 2010-08-09 14:11 ` Denis Kenzior
0 siblings, 0 replies; 2+ messages in thread
From: Denis Kenzior @ 2010-08-09 14:11 UTC (permalink / raw)
To: ofono
[-- Attachment #1: Type: text/plain, Size: 802 bytes --]
Hi Zhenhua,
On 08/09/2010 04:28 AM, Zhenhua Zhang wrote:
> Similiar to pri_deactive_callback, we should release the context id in
> gprs_deactive_for_remove() as well.
> ---
> src/gprs.c | 3 +++
> 1 files changed, 3 insertions(+), 0 deletions(-)
>
> diff --git a/src/gprs.c b/src/gprs.c
> index 8d807dd..2c5bb4e 100644
> --- a/src/gprs.c
> +++ b/src/gprs.c
> @@ -1262,6 +1262,9 @@ static void gprs_deactivate_for_remove(const struct ofono_error *error,
> return;
> }
>
> + gprs_cid_release(gprs, ctx->context.cid);
> + ctx->context.cid = 0;
> +
> if (gprs->settings) {
> g_key_file_remove_group(gprs->settings, ctx->key, NULL);
> storage_sync(gprs->imsi, SETTINGS_STORE, gprs->settings);
Great catch. Patch has been applied, thanks.
Regards,
-Denis
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-08-09 14:11 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-08-09 9:28 [PATCH] gprs: Fix release cid in gprs_deactive_for_remove Zhenhua Zhang
2010-08-09 14:11 ` Denis Kenzior
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.