On Tuesday, 29 January 2013 at 00:49:07 UTC, bioinfornatics wrote:
I missed to show the code

$ cat test_mmap.d
import std.stdio;
import std.mmfile;

void main(string[] args ){
    MmFile m = new MmFile( args[0] );
    foreach( ulong c; 0..m.length )
        writeln( m[c], " ", cast(dchar) m[c] );
}

 MmFile m = new MmFile( args[0] ); ?
Didn't you mean args[1] or something?
Because now you are reading your binary file and output is correct, its spits out elf header info.

My guess is your are passing file with DNA (or whatever it is) via command line arguments

Reply via email to