~kklimonda/ubuntu/natty/glibmm2.4/update

« back to all changes in this revision

Viewing changes to tests/giomm_ioerror/main.cc

  • Committer: Bazaar Package Importer
  • Author(s): Deng Xiyue
  • Date: 2008-10-21 22:29:45 UTC
  • mfrom: (1.2.32 upstream)
  • Revision ID: james.westby@ubuntu.com-20081021222945-14plcglhrbjbz3c2
Tags: 2.18.1-1
* New upstream stable release.
* Use POSIX standard regex classes in sed trick in debian/rules.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
// Some libraries define HOST_NOT_FOUND.  Make sure we can still compile fine
 
2
// even if this is the case:
 
3
#define HOST_NOT_FOUND 1
 
4
 
1
5
#include <giomm.h>
2
6
#include <iostream>
3
7
#include <string.h>
4
8
 
 
9
// This is just to test a workaround in the error.h header.  We save and #undef
 
10
// HOST_NOT_FOUND if it was defined by another header, and then restore it at
 
11
// the end of the header.  Here I'm just making sure that our temporary value
 
12
// doesn't remain set
 
13
#ifdef GIOMM_SAVED_HOST_NOT_FOUND
 
14
#error Forgot to #undef GIOMM_SAVED_HOST_NOT_FOUND
 
15
#endif
 
16
 
5
17
int main(int argc, char** argv)
6
18
{
7
19
  Glib::init();