| Date: Wed, 16 Jun 2004 03:12:39 +0000
extra assertion, fix leak in vtread
Diffstat:
M src/libventi/client.c | 1 +
M src/libventi/file.c | 2 ++
2 files changed, 3 insertions(+), 0 deletions(-)
--- |
| t@@ -98,6 +98,7 @@ vtread(VtConn *z, uchar score[VtScoreSize], uint type, uchar *buf, int n)
nn = packetsize(p);
if(packetconsume(p, buf, nn) < 0)
abort();
+ packetfree(p);
return nn;
}
|
| t@@ -190,6 +190,8 @@ vtfilecreate(VtFile *r, int psize, int dsize, int dir)
u32int offset;
assert(ISLOCKED(r));
+ assert(psize <= VtMaxLumpSize);
+ assert(dsize <= VtMaxLumpSize);
if(!r->dir){
werrstr(ENotDir); |