- std::string filename = format("/tmp/mspdatatool.%d", i);
- /*filename.reserve(25);
- filename.append("/tmp/mspdatatool.");
- for(unsigned i=0; i<8; ++i)
- filename.append(rand());*/
- IO::File *file = new IO::File(filename, IO::M_RDWR, IO::File::C_NEW);
- FS::unlink(filename);
+ FS::Path filename = tmpdir/format("mspdatatool.%d", i);
+ IO::BufferedFile *file = new IO::BufferedFile(filename.str(), IO::M_RDWR, IO::File::C_NEW);
+ FS::unlink(filename.str());