summaryrefslogtreecommitdiff
path: root/networking
diff options
context:
space:
mode:
authorEric Andersen2001-11-10 11:16:39 +0000
committerEric Andersen2001-11-10 11:16:39 +0000
commit744a194f53b0e524814a4e40e05d621e6c4222a0 (patch)
treed60c92b82bc33618f843d61f07565894a50f83f1 /networking
parentc52a6b0f1023268f021d04ddf224db5c5dd7b13e (diff)
downloadbusybox-744a194f53b0e524814a4e40e05d621e6c4222a0.zip
busybox-744a194f53b0e524814a4e40e05d621e6c4222a0.tar.gz
Can't use RESERVE_CONFIG_BUFFER here since the allocation
size varies meaning BUFFERS_GO_ON_STACK will fail
Diffstat (limited to 'networking')
-rw-r--r--networking/tftp.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/networking/tftp.c b/networking/tftp.c
index 38a6f81..1e5dddb 100644
--- a/networking/tftp.c
+++ b/networking/tftp.c
@@ -162,7 +162,9 @@ static inline int tftp(const int cmd, const struct hostent *host,
int want_option_ack = 0;
#endif
- RESERVE_CONFIG_BUFFER(buf, tftp_bufsize + 4); /* Opcode + Block # + Data */
+ /* Can't use RESERVE_CONFIG_BUFFER here since the allocation
+ * size varies meaning BUFFERS_GO_ON_STACK would fail */
+ char *buf=xmalloc(tftp_bufsize + 4);
tftp_bufsize += 4;