Skip to content
Snippets Groups Projects
Commit 519494cd authored by deuce's avatar deuce
Browse files

Open the file shareable with a buffer size equal to record size.

parent 0fa22c8c
No related branches found
No related tags found
No related merge requests found
......@@ -29,10 +29,10 @@ function GetRecordLength(RecordDef)
function RecordFile(filename, definition)
{
this.file=new File(filename);
if(!this.file.open(file_exists(this.file.name)?"rb+":"wb+"))
this.RecordLength=GetRecordLength(this.fields);
if(!this.file.open(file_exists(this.file.name)?"rb+":"wb+",true,this.RecordLength))
return(null);
this.fields=definition;
this.RecordLength=GetRecordLength(this.fields);
this.length=this.file.length/this.RecordLength;
/* Read a record by index */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment