mirror of
https://github.com/9fans/plan9port.git
synced 2025-01-24 11:41:58 +00:00
venti: fix vtcachealloc and VtMaxLumpSize
R=rsc CC=plan9port.codebot http://codereview.appspot.com/5309073
This commit is contained in:
parent
4544da5200
commit
db60da46b3
3 changed files with 14 additions and 2 deletions
|
@ -4,6 +4,12 @@
|
|||
#include <libsec.h>
|
||||
#include <thread.h>
|
||||
|
||||
enum
|
||||
{
|
||||
// XXX What to do here?
|
||||
VtMaxLumpSize = 65536,
|
||||
};
|
||||
|
||||
int chatty;
|
||||
|
||||
void
|
||||
|
@ -92,7 +98,7 @@ threadmain(int argc, char *argv[])
|
|||
sysfatal("not a single file");
|
||||
|
||||
// open and read file
|
||||
c = vtcachealloc(z, root.blocksize, 32);
|
||||
c = vtcachealloc(z, root.blocksize*32);
|
||||
if(c == nil)
|
||||
sysfatal("vtcachealloc: %r");
|
||||
f = vtfileopenroot(c, &e);
|
||||
|
|
|
@ -4,6 +4,12 @@
|
|||
#include <venti.h>
|
||||
#include <bio.h>
|
||||
|
||||
enum
|
||||
{
|
||||
// XXX What to do here?
|
||||
VtMaxLumpSize = 65536,
|
||||
};
|
||||
|
||||
char *host;
|
||||
Biobuf b;
|
||||
VtConn *z;
|
||||
|
|
|
@ -65,7 +65,7 @@ threadmain(int argc, char *argv[])
|
|||
sysfatal("vtconnect: %r");
|
||||
|
||||
// write file
|
||||
c = vtcachealloc(z, Blocksize, 32);
|
||||
c = vtcachealloc(z, Blocksize*32);
|
||||
if(c == nil)
|
||||
sysfatal("vtcachealloc: %r");
|
||||
f = vtfilecreateroot(c, Blocksize, Blocksize, VtDataType);
|
||||
|
|
Loading…
Reference in a new issue