From b6f57560fb7fae00f0854ca19158bd5512e5405b Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Wed, 1 Oct 2008 21:48:33 +0000 Subject: This commit is sure to break things. This should be a very, very minor change. What changed API-Wise: - I deleted a constructor in Bu::File that shouldn't have been used anyway. - I changed it from using fopen style mode strings to using libbu++ style mode flags. Check the docs for the complete list, but basically instead of "wb" you do Bu::File::Write, and so on, you can or any of the libbu++ flags together. There is no binary/text mode, it just writes whatever you tell it to verbatim (binary mode). Lots of extras are supported. Nothing else should have changed (except now the file stream is unbuffered, like all the other streams). Sorry if this breaks anything, if it's too annoying, use the last revision for a while longer. --- src/unit/taf.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/unit/taf.cpp') diff --git a/src/unit/taf.cpp b/src/unit/taf.cpp index 4e22ab1..0a97eba 100644 --- a/src/unit/taf.cpp +++ b/src/unit/taf.cpp @@ -29,14 +29,14 @@ public: { #define FN_TMP ("/tmp/tmpXXXXXXXX") Bu::FString sFnTmp(FN_TMP); - Bu::File fOut = Bu::File::tempFile( sFnTmp, "wb" ); + Bu::File fOut = Bu::File::tempFile( sFnTmp, Bu::File::Write ); const char *data = "{test: name=\"Bob\"}" ; fOut.write(data,strlen(data)); fOut.close(); - Bu::File fIn(sFnTmp.getStr(), "rb"); + Bu::File fIn(sFnTmp.getStr(), Bu::File::Read ); Bu::TafReader tr(fIn); Bu::TafGroup *tn = tr.readGroup(); -- cgit v1.2.3