summaryrefslogtreecommitdiff
path: root/src/hftctl.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/hftctl.c')
-rw-r--r--src/hftctl.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/hftctl.c b/src/hftctl.c
index 6ba1e2fb7fd..1b460500b0c 100644
--- a/src/hftctl.c
+++ b/src/hftctl.c
@@ -79,7 +79,7 @@ typedef int (*FUNC)(); /* pointer to a function */
static int hfqry();
static int hfskbd();
- char *malloc();
+ char *xmalloc();
extern int errno;
static jmp_buf hftenv;
@@ -319,7 +319,7 @@ WR_REQ (fd, request, cmdlen, cmd, resplen)
if (cmdlen) /* if arg structure to pass */
{
size = sizeof (struct hfctlreq) + cmdlen;
- if ((p.c = malloc(size)) == NULL) /* malloc one area */
+ if ((p.c = xmalloc(size)) == NULL) /* malloc one area */
return (-1);
memcpy (p.c, &req, sizeof (req)); /* copy CTL REQ struct */
@@ -334,7 +334,7 @@ WR_REQ (fd, request, cmdlen, cmd, resplen)
/* write request to terminal */
if (write(fd,p.c,size) == -1) return (-1);
if (p.req != &req) /* free if allocated */
- free (p.c);
+ xfree (p.c);
return (0);
}