mirror of
https://github.com/9fans/plan9port.git
synced 2025-01-15 11:20:03 +00:00
14 lines
208 B
C
14 lines
208 B
C
|
#include <u.h>
|
||
|
#include <libc.h>
|
||
|
#include "libString.h"
|
||
|
|
||
|
void
|
||
|
s_putc(String *s, int c)
|
||
|
{
|
||
|
if(s->ref > 1)
|
||
|
sysfatal("can't s_putc a shared string");
|
||
|
if (s->ptr >= s->end)
|
||
|
s_grow(s, 2);
|
||
|
*(s->ptr)++ = c;
|
||
|
}
|