summaryrefslogtreecommitdiff
path: root/libwmc
diff options
context:
space:
mode:
authorM. I. Spozta <mispozta@gmail.com>2012-03-22 11:34:39 -0500
committerDan Williams <dcbw@redhat.com>2012-03-22 11:34:39 -0500
commitac92ac74984a75ca4e125c0eabf8acba048a2b35 (patch)
tree91efd3dc62f76cff07f48ffa7ad6dd5111d9c8f6 /libwmc
parentc5a6e1fcab44df046569ed77f6f67149b9d671d2 (diff)
wmc: increase estimate decapsulation buffer size
(dcbw) Some packets are much larger and require a lot more escaping than we thought so we need larger buffers here to be able to handle all packets. In this case, SMS receipt.
Diffstat (limited to 'libwmc')
-rw-r--r--libwmc/src/utils.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libwmc/src/utils.c b/libwmc/src/utils.c
index 36dff6a3..059038ca 100644
--- a/libwmc/src/utils.c
+++ b/libwmc/src/utils.c
@@ -254,7 +254,7 @@ uml290_wmc_encapsulate (char *inbuf,
estimated_out_len = cmd_len + strlen (AT_WMC_PREFIX);
estimated_out_len += 3; /* CRC + trailer */
- estimated_out_len += cmd_len * 1.3; /* escaping */
+ estimated_out_len += cmd_len * 2; /* escaping */
wmc_return_val_if_fail (outbuf_len > estimated_out_len, 0);
memcpy (outbuf, AT_WMC_PREFIX, strlen (AT_WMC_PREFIX));