mirror of /home/gitosis/repositories/libowfat.git
fix scan_to_sa (Tim Lorenz)
This commit is contained in:
parent
3ed5acbc60
commit
becc322e12
1
CHANGES
1
CHANGES
|
@ -1,4 +1,5 @@
|
|||
0.24:
|
||||
fix scan_to_sa (Tim Lorenz)
|
||||
|
||||
0.23:
|
||||
also recognize EPFNOSUPPORT as EAFNOSUPPORT (groan)
|
||||
|
|
|
@ -4,10 +4,10 @@
|
|||
|
||||
unsigned long scan_to_sa(unsigned long (*func)(const char*,char*,unsigned long*),
|
||||
const char* src,stralloc* sa) {
|
||||
unsigned long scanned;
|
||||
unsigned long written;
|
||||
unsigned long r;
|
||||
if (!stralloc_readyplus(sa,str_len(src))) return 0;
|
||||
if ((r=func(src,sa->s+sa->len,&scanned)))
|
||||
sa->len+=r;
|
||||
if ((r=func(src,sa->s+sa->len,&written)))
|
||||
sa->len+=written;
|
||||
return r;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue