Release 980201
[wine] / misc / stress.c
1 #include <stdio.h>
2 #include <limits.h>
3 #include "windows.h"
4 #include "stress.h"
5 #include "stddebug.h"
6 /* #define DEBUG_STRESS */
7 /* #undef  DEBUG_STRESS */
8 #include "debug.h"
9
10
11 int WINAPI AllocDiskSpace(long lLeft, UINT16 uDrive)
12 {
13         dprintf_stress(stdnimp, "stress.dll: AllocDiskSpace %d, %ld\n", uDrive, lLeft);
14
15         return 1;
16 }
17
18 int WINAPI AllocFileHandles(int Left)
19 {
20         dprintf_stress(stddeb, "stress.dll: AllocFileHandles %d\n", Left);
21
22         if (Left < 0)
23                 return -1;
24         else
25                 return 1;
26 }
27
28 BOOL16 WINAPI AllocGDIMem(UINT16 uLeft)
29 {
30         dprintf_stress(stddeb, "stress.dll: AllocGDIMem %d\n", uLeft);
31
32         return 1;
33 }
34
35 BOOL16 WINAPI AllocMem(DWORD dwLeft)
36 {
37         dprintf_stress(stdnimp, "stress.dll: AllocMem %ld\n", dwLeft);
38
39         return 1;
40 }
41
42 BOOL16 WINAPI AllocUserMem(UINT16 uContig)
43 {
44         dprintf_stress(stddeb, "stress.dll: AllocUserMem %d\n", uContig);
45
46         return 1;
47 }
48
49 void WINAPI FreeAllMem(void)
50 {
51         dprintf_stress(stddeb, "stress.dll: FreeAllMem\n");
52 }
53
54 void WINAPI FreeAllGDIMem(void)
55 {
56         dprintf_stress(stddeb, "stress.dll: FreeAllGDIMem\n");
57 }
58
59 void WINAPI FreeAllUserMem(void)
60 {
61         dprintf_stress(stddeb, "stress.dll: FreeAllUserMem\n");
62 }
63
64 void WINAPI GetFreeAllUserMem(void)
65 {
66        dprintf_stress(stddeb, "stress.dll: GetFreeAllUserMem\n");
67 }
68
69 int WINAPI GetFreeFileHandles(void)
70 {
71         dprintf_stress(stddeb, "stress.dll: GetFreeFileHandles\n");
72
73 #ifndef OPEN_MAX
74         return _POSIX_OPEN_MAX;
75 #else
76         return OPEN_MAX;
77 #endif
78 }
79
80 void WINAPI UnAllocDiskSpace(UINT16 drive)
81 {
82         dprintf_stress(stddeb, "stress.dll: UnAllocDiskSpace %d\n", drive);
83 }
84
85 void WINAPI UnAllocFileHandles(void)
86 {
87         dprintf_stress(stddeb, "stress.dll: GetFreeAllUserMem\n");
88 }