File:  [ELWIX - Embedded LightWeight unIX -] / libaitio / example / Attic / astvar.c
Revision 1.2.16.1: download - view: text, annotated - select for diffs - revision graph
Thu Nov 3 14:22:52 2011 UTC (12 years, 8 months ago) by misho
Branches: io2_2
Diff to: branchpoint 1.2: preferred, colored
rename func

#include <stdio.h>
#include <aitio.h>

int
main(int argc, char **argv)
{
	char *str;

	if (argc < 2) {
		printf("Syntax: %s <var (like {99999[:9:9]})>\n", argv[0]);
		return 1;
	}

	str = ioStrAst(argv[1]);
	if (!str) {
		printf("#%d - %s\n", io_GetErrno(), io_GetError());
		return 1;
	}

	printf(">>> %s\n", str);

	free(str);
	return 0;
}

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>