]> git.saurik.com Git - apple/dyld.git/blame - unit-tests/test-cases/upward-dylib/up.c
dyld-851.27.tar.gz
[apple/dyld.git] / unit-tests / test-cases / upward-dylib / up.c
CommitLineData
412ebb8e
A
1#include <stdio.h>
2#include "down.h"
3
4static int state = 0;
5
6#ifndef STUB
7// should run second because up.dylib is higher than down.dylib
8static __attribute__((constructor)) void myInit1()
9{
10 //fprintf(stderr, "myInit1()\n");
11 if ( getdown() ) {
12 state = 1;
13 }
14}
15#endif
16
17int whatsup()
18{
19 return state;
20}
21