plan9port/src/lib9/fmt/fmtstr.c

17 lines
292 B
C
Raw Normal View History

2006-05-21 20:49:16 +00:00
/* Copyright (c) 2002-2006 Lucent Technologies; see LICENSE */
2004-12-26 21:50:14 +00:00
#include <stdlib.h>
2004-12-26 23:07:37 +00:00
#include <stdarg.h>
2004-12-26 21:50:14 +00:00
#include "plan9.h"
#include "fmt.h"
#include "fmtdef.h"
char*
fmtstrflush(Fmt *f)
{
2004-12-26 23:07:37 +00:00
if(f->start == nil)
return nil;
*(char*)f->to = '\0';
2006-05-21 20:49:16 +00:00
f->to = f->start;
return (char*)f->start;
}