hfpmodem: Remove useless NULL checks before g_free

This commit is contained in:
Marcel Holtmann 2010-08-16 22:06:00 +02:00
parent 3ea7893108
commit 41133da001
3 changed files with 8 additions and 16 deletions

View File

@ -86,7 +86,6 @@ static void hfp_speaker_volume(struct ofono_call_volume *cv,
return;
error:
if (cbd)
g_free(cbd);
CALLBACK_WITH_FAILURE(cb, data);
@ -114,7 +113,6 @@ static void hfp_microphone_volume(struct ofono_call_volume *cv,
return;
error:
if (cbd)
g_free(cbd);
CALLBACK_WITH_FAILURE(cb, data);

View File

@ -247,7 +247,6 @@ static void hfp_registration_status(struct ofono_netreg *netreg,
return;
error:
if (cbd)
g_free(cbd);
CALLBACK_WITH_FAILURE(cb, -1, -1, -1, -1, data);
@ -295,7 +294,6 @@ static void hfp_signal_strength(struct ofono_netreg *netreg,
return;
error:
if (cbd)
g_free(cbd);
CALLBACK_WITH_FAILURE(cb, -1, data);

View File

@ -380,7 +380,6 @@ static void hfp_dial(struct ofono_voicecall *vc,
return;
error:
if (cbd)
g_free(cbd);
CALLBACK_WITH_FAILURE(cb, data);
@ -406,7 +405,6 @@ static void hfp_template(const char *cmd, struct ofono_voicecall *vc,
return;
error:
if (req)
g_free(req);
CALLBACK_WITH_FAILURE(cb, data);
@ -523,7 +521,6 @@ static void hfp_release_specific(struct ofono_voicecall *vc, int id,
return;
error:
if (req)
g_free(req);
CALLBACK_WITH_FAILURE(cb, data);
@ -612,7 +609,6 @@ static void hfp_send_dtmf(struct ofono_voicecall *vc, const char *dtmf,
return;
error:
if (req)
g_free(req);
CALLBACK_WITH_FAILURE(cb, data);