From 72110961f1a411863cd833877b960581fe38a428 Mon Sep 17 00:00:00 2001 From: Moritz Schulte Date: Sun, 31 Aug 2008 11:55:09 +0000 Subject: 2008-08-30 Moritz * scdaemon.c (main): Use estream_asprintf instead of asprintf. * command.c (update_reader_status_file): Likewise. (cmd_serialno): Use estream_asprintf instead of asprintf and xfree instead of free to release memory allocated through (estream_)asprintf. (cmd_learn): Likewise. (pin_cb): Likewise. * app-openpgp.c (get_public_key): Likewise. --- scd/scdaemon.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'scd/scdaemon.c') diff --git a/scd/scdaemon.c b/scd/scdaemon.c index a8a3bcff5..68119f592 100644 --- a/scd/scdaemon.c +++ b/scd/scdaemon.c @@ -702,8 +702,8 @@ main (int argc, char **argv ) close (fd); /* create the info string: :: */ - if (asprintf (&infostr, "SCDAEMON_INFO=%s:%lu:1", - socket_name, (ulong)pid ) < 0) + if (estream_asprintf (&infostr, "SCDAEMON_INFO=%s:%lu:1", + socket_name, (ulong) pid) < 0) { log_error ("out of core\n"); kill (pid, SIGTERM); @@ -738,7 +738,7 @@ main (int argc, char **argv ) { printf ( "%s; export SCDAEMON_INFO;\n", infostr); } - free (infostr); + xfree (infostr); exit (0); } /* NOTREACHED */ -- cgit v1.2.3