mirror of git://git.sysmocom.de/ofono
isimodem: Minor style fixes
This commit is contained in:
parent
4ca9022358
commit
9b5ea0189a
|
@ -139,8 +139,7 @@ static gboolean decode_gsm_forwarding_info(GIsiSubBlockIter *parent,
|
|||
return FALSE;
|
||||
|
||||
if (info->numlen != 0) {
|
||||
|
||||
if (!g_isi_sb_iter_get_alpha_tag(&iter, &tag,
|
||||
if (!g_isi_sb_iter_get_alpha_tag(&iter, &tag,
|
||||
info->numlen * 2,
|
||||
2 + len))
|
||||
return FALSE;
|
||||
|
|
|
@ -1083,6 +1083,6 @@ void isi_trace(const GIsiMessage *msg, void *data)
|
|||
const char *resname = pn_resource_name(res);
|
||||
const char *name = res_to_name(res, id);
|
||||
|
||||
hex_dump(resname, res, name, id, g_isi_msg_utid(msg), g_isi_msg_data(msg),
|
||||
g_isi_msg_data_len(msg));
|
||||
hex_dump(resname, res, name, id, g_isi_msg_utid(msg),
|
||||
g_isi_msg_data(msg), g_isi_msg_data_len(msg));
|
||||
}
|
||||
|
|
|
@ -117,7 +117,7 @@ static inline int isi_status_to_at_status(struct reg_info *reg)
|
|||
return 4;
|
||||
}
|
||||
|
||||
static inline int isi_tech_to_at_tech(struct rat_info *rat, struct gsm_info *gsm)
|
||||
static inline int isi_to_at_tech(struct rat_info *rat, struct gsm_info *gsm)
|
||||
{
|
||||
int tech = -1;
|
||||
|
||||
|
@ -221,7 +221,7 @@ static void reg_status_ind_cb(const GIsiMessage *msg, void *data)
|
|||
|
||||
ofono_netreg_status_notify(netreg, isi_status_to_at_status(&nd->reg),
|
||||
nd->gsm.lac, nd->gsm.ci,
|
||||
isi_tech_to_at_tech(&nd->rat, &nd->gsm));
|
||||
isi_to_at_tech(&nd->rat, &nd->gsm));
|
||||
}
|
||||
|
||||
static gboolean parse_rat_info(GIsiSubBlockIter *iter, struct rat_info *rat)
|
||||
|
@ -263,7 +263,7 @@ static void rat_ind_cb(const GIsiMessage *msg, void *data)
|
|||
|
||||
ofono_netreg_status_notify(netreg, isi_status_to_at_status(&nd->reg),
|
||||
nd->gsm.lac, nd->gsm.ci,
|
||||
isi_tech_to_at_tech(&nd->rat, &nd->gsm));
|
||||
isi_to_at_tech(&nd->rat, &nd->gsm));
|
||||
}
|
||||
|
||||
static void reg_status_resp_cb(const GIsiMessage *msg, void *data)
|
||||
|
@ -299,7 +299,7 @@ static void reg_status_resp_cb(const GIsiMessage *msg, void *data)
|
|||
|
||||
CALLBACK_WITH_SUCCESS(cb, isi_status_to_at_status(&nd->reg),
|
||||
nd->gsm.lac, nd->gsm.ci,
|
||||
isi_tech_to_at_tech(&nd->rat, &nd->gsm),
|
||||
isi_to_at_tech(&nd->rat, &nd->gsm),
|
||||
cbd->data);
|
||||
g_free(cbd);
|
||||
return;
|
||||
|
@ -409,7 +409,10 @@ static void name_get_resp_cb(const GIsiMessage *msg, void *data)
|
|||
if (!g_isi_sb_iter_get_byte(&iter, &len, 3))
|
||||
goto error;
|
||||
|
||||
if (!g_isi_sb_iter_get_alpha_tag(&iter, &tag, len * 2, 4))
|
||||
/* Name is UCS-2 encoded */
|
||||
len *= 2;
|
||||
|
||||
if (!g_isi_sb_iter_get_alpha_tag(&iter, &tag, len, 4))
|
||||
goto error;
|
||||
|
||||
strncpy(op.name, tag, OFONO_MAX_OPERATOR_NAME_LENGTH);
|
||||
|
|
|
@ -80,7 +80,7 @@ static gboolean parse_sne(GIsiSubBlockIter *iter, char **sne)
|
|||
uint8_t len;
|
||||
|
||||
if (!g_isi_sb_iter_get_byte(iter, &len, 6))
|
||||
return FALSE;
|
||||
return FALSE;
|
||||
|
||||
if (!g_isi_sb_iter_get_alpha_tag(iter, sne, len * 2, 8))
|
||||
return FALSE;
|
||||
|
|
|
@ -534,7 +534,7 @@ static gboolean parse_gsm_tpdu(GIsiSubBlockIter *parent, struct sms_addr *add,
|
|||
case SMS_ADDRESS:
|
||||
|
||||
if (!parse_sms_address(&iter, add))
|
||||
return FALSE;
|
||||
return FALSE;
|
||||
|
||||
if (add->type != SMS_GSM_0411_ADDRESS)
|
||||
return FALSE;
|
||||
|
|
Loading…
Reference in New Issue