]> Creatis software - gdcm.git/blob - Testing/TestBug.cxx
Fix mistypings
[gdcm.git] / Testing / TestBug.cxx
1 /*=========================================================================
2                                                                                 
3   Program:   gdcm
4   Module:    $RCSfile: TestBug.cxx,v $
5   Language:  C++
6   Date:      $Date: 2007/05/23 14:18:06 $
7   Version:   $Revision: 1.24 $
8                                                                                 
9   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
10   l'Image). All rights reserved. See Doc/License.txt or
11   http://www.creatis.insa-lyon.fr/Public/Gdcm/License.html for details.
12                                                                                 
13      This software is distributed WITHOUT ANY WARRANTY; without even
14      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15      PURPOSE.  See the above copyright notices for more information.
16                                                                                 
17 =========================================================================*/
18 // The following crashes on Win32
19 // We have to be carefull when the code both use cout + printf VC++ gets
20 // confused, thus make sure we use only one kind of iostream
21
22 #include "gdcmFile.h"
23
24 int TestBug(int argc, char *argv[])
25 {  
26 std::cout << "==========test" <<std::endl;
27   GDCM_NAME_SPACE::File *f;
28   f = GDCM_NAME_SPACE::File::New();
29   
30    if (argc > 1)
31       f->SetFileName( argv[1] );
32    else {
33       std::string filename = GDCM_DATA_ROOT;
34       filename += "/test.acr";
35       f->SetFileName( filename.c_str() );
36    }
37    f->Load( );
38   // f->Print();
39    std::cout << "-------------End of Print file ------------" << std::cout;   
40    //f->GetPubDict()->Print();
41    std::cout << "-------------End of Print Dict ------------" << std::cout;   
42    f->Delete();
43
44    return 0;
45 }