X-Git-Url: https://www.ginac.de/ginac.git//ginac.git?p=ginac.git;a=blobdiff_plain;f=tools%2Fviewgar.cpp;h=f4a8d3c4d5422b727b4c5d7a2926853ce98649f7;hp=19f27df149762da615bcf25a5743feca05015f1e;hb=6afbb9793e359cf388462c471ea256a6662b0cd4;hpb=9711eff3300caffadf44b3b1bf7c6e096f26bfaa diff --git a/tools/viewgar.cpp b/tools/viewgar.cpp index 19f27df1..f4a8d3c4 100644 --- a/tools/viewgar.cpp +++ b/tools/viewgar.cpp @@ -3,7 +3,7 @@ * GiNaC archive file viewer. */ /* - * GiNaC Copyright (C) 1999-2001 Johannes Gutenberg University Mainz, Germany + * GiNaC Copyright (C) 1999-2009 Johannes Gutenberg University Mainz, Germany * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -17,22 +17,22 @@ * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ -#include -#include -#include -#include - #include "ginac.h" - using namespace GiNaC; +#include +#include +#include +#include +using namespace std; + int main(int argc, char **argv) { if (argc < 2) { - fprintf(stderr, "Usage: %s [-d] file...\n", argv[0]); + cerr << "Usage: " << argv[0] << " [-d] file..." << endl; exit(1); } --argc; ++argv; @@ -45,7 +45,7 @@ int main(int argc, char **argv) dump_mode = true; --argc; ++argv; } - std::ifstream f(*argv); + std::ifstream f(*argv, std::ios_base::binary); archive ar; f >> ar; if (dump_mode) {