store filename when creating buffer; add file module