diff options
Diffstat (limited to 'regress/libexec/ld.so/constructor/libab/ab.C')
-rw-r--r-- | regress/libexec/ld.so/constructor/libab/ab.C | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/regress/libexec/ld.so/constructor/libab/ab.C b/regress/libexec/ld.so/constructor/libab/ab.C new file mode 100644 index 00000000000..574d67fbbee --- /dev/null +++ b/regress/libexec/ld.so/constructor/libab/ab.C @@ -0,0 +1,22 @@ +/* + * Public Domain 2003 Dale Rahn + * + * $OpenBSD: ab.C,v 1.1 2003/02/01 19:56:17 drahn Exp $ + */ + +#include "iostream.h" +#include "aa.h" +#include "ab.h" + +extern int a; + +BB::BB(char *str) +{ + if (a == 0) { + cout << "A not intialized in B constructors " << a << "\n"; + exit(1); + } +} + +BB ab("local"); +AA aa("B"); |