aboutsummaryrefslogtreecommitdiff
path: root/libntp/inttoa.c
blob: f34710e1c8083376bd47c1c0fe7eaef15776a6c6 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
/*
 * inttoa - return an asciized signed integer
 */
#include <config.h>
#include <stdio.h>

#include "lib_strbuf.h"
#include "ntp_stdlib.h"

char *
inttoa(
	long val
	)
{
	register char *buf;

	LIB_GETBUF(buf);
	snprintf(buf, LIB_BUFLENGTH, "%ld", val);

	return buf;
}