summaryrefslogtreecommitdiffstats
path: root/drivers/isdn/hardware/eicon
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/isdn/hardware/eicon')
-rw-r--r--drivers/isdn/hardware/eicon/message.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/drivers/isdn/hardware/eicon/message.c b/drivers/isdn/hardware/eicon/message.c
index ae89fb8..4bd469b 100644
--- a/drivers/isdn/hardware/eicon/message.c
+++ b/drivers/isdn/hardware/eicon/message.c
@@ -8423,17 +8423,17 @@ static word add_b23(PLCI *plci, API_PARSE *bp)
pos = 0;
else
{
- ((T30_INFO *)&nlc[1])->station_id[20 + pos++] = ' ';
- ((T30_INFO *)&nlc[1])->station_id[20 + pos++] = ' ';
+ nlc[1 + offsetof(T30_INFO, station_id) + 20 + pos++] = ' ';
+ nlc[1 + offsetof(T30_INFO, station_id) + 20 + pos++] = ' ';
len = (byte)b3_config_parms[2].length;
if (len > 20)
len = 20;
if (CAPI_MAX_DATE_TIME_LENGTH + 2 + len + 2 + b3_config_parms[3].length <= CAPI_MAX_HEAD_LINE_SPACE)
{
for (i = 0; i < len; i++)
- ((T30_INFO *)&nlc[1])->station_id[20 + pos++] = ((byte *)b3_config_parms[2].info)[1+i];
- ((T30_INFO *)&nlc[1])->station_id[20 + pos++] = ' ';
- ((T30_INFO *)&nlc[1])->station_id[20 + pos++] = ' ';
+ nlc[1 + offsetof(T30_INFO, station_id) + 20 + pos++] = ((byte *)b3_config_parms[2].info)[1+i];
+ nlc[1 + offsetof(T30_INFO, station_id) + 20 + pos++] = ' ';
+ nlc[1 + offsetof(T30_INFO, station_id) + 20 + pos++] = ' ';
}
}
}
@@ -8444,9 +8444,8 @@ static word add_b23(PLCI *plci, API_PARSE *bp)
((T30_INFO *)&nlc[1])->head_line_len = (byte)(pos + len);
nlc[0] += (byte)(pos + len);
for (i = 0; i < len; i++)
- ((T30_INFO *)&nlc[1])->station_id[20 + pos++] = ((byte *)b3_config_parms[3].info)[1+i];
- }
- else
+ nlc[1 + offsetof(T30_INFO, station_id) + 20 + pos++] = ((byte *)b3_config_parms[3].info)[1+i];
+ } else
((T30_INFO *)&nlc[1])->head_line_len = 0;
plci->nsf_control_bits = 0;
OpenPOWER on IntegriCloud