HCoop
/
hcoop
/
zz_old
/
debian
/
djbdns.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
blame
|
history
|
raw
|
HEAD
release
[hcoop/zz_old/debian/djbdns.git]
/
stralloc_opyb.c
1
#include
"stralloc.h"
2
#include
"byte.h"
3
4
int
stralloc_copyb
(
stralloc
*
sa
,
const char
*
s
,
unsigned int
n
)
5
{
6
if
(!
stralloc_ready
(
sa
,
n
+
1
))
return
0
;
7
byte_copy
(
sa
->
s
,
n
,
s
);
8
sa
->
len
=
n
;
9
sa
->
s
[
n
] =
'Z'
;
/* ``offensive programming'' */
10
return
1
;
11
}