source: trunk/src/kernel32/stubs.cpp@ 5355

Last change on this file since 5355 was 5308, checked in by sandervl, 24 years ago

removed builtin.h include + initterm update

File size: 90.6 KB
Line 
1
2/*
3 * Win32 KERNEL32 Subsystem for OS/2
4 *
5 * 1998/05/19 PH Patrick Haller (haller@zebra.fh-weingarten.de)
6 *
7 * @(#) Stubs.H 1.0.0 1998/05/19 PH start
8 *
9 * Project Odin Software License can be found in LICENSE.TXT
10 *
11 */
12
13/*****************************************************************************
14 * Includes *
15 *****************************************************************************/
16#include <os2win.h>
17#include <winnls.h>
18#include "unicode.h"
19#include "handlemanager.h"
20#include <string.h>
21
22#include "stubs.h"
23
24#define DBG_LOCALLOG DBG_stubs
25#include "dbglocal.h"
26
27
28/*****************************************************************************
29 * Defines *
30 *****************************************************************************/
31
32
33// For DefineDosDevice
34
35#define DDD_RAW_TARGET_PATH 0x00000001
36#define DDD_REMOVE_DEFINITION 0x00000002
37#define DDD_EXACT_MATCH_ON_REMOVE 0x00000004
38#define DDD_NO_BROADCAST_SYSTEM 0x00000008
39
40
41// For Backup functions
42
43//
44// Stream Ids
45//
46
47#define BACKUP_INVALID 0x00000000
48#define BACKUP_DATA 0x00000001
49#define BACKUP_EA_DATA 0x00000002
50#define BACKUP_SECURITY_DATA 0x00000003
51#define BACKUP_ALTERNATE_DATA 0x00000004
52#define BACKUP_LINK 0x00000005
53#define BACKUP_PROPERTY_DATA 0x00000006
54
55//
56// Stream Attributes
57//
58
59#define STREAM_NORMAL_ATTRIBUTE 0x00000000
60#define STREAM_MODIFIED_WHEN_READ 0x00000001
61#define STREAM_CONTAINS_SECURITY 0x00000002
62#define STREAM_CONTAINS_PROPERTIES 0x00000004
63
64
65// Locale
66#define LCID DWORD
67
68/*
69 * Locale Dependent Mapping Flags.
70 */
71
72#define LCMAP_LOWERCASE 0x00000100 /* lower case letters */
73#define LCMAP_UPPERCASE 0x00000200 /* upper case letters */
74#define LCMAP_SORTKEY 0x00000400 /* WC sort key (normalize) */
75#define LCMAP_BYTEREV 0x00000800 /* byte reversal */
76
77#define LCMAP_HIRAGANA 0x00100000 /* map katakana to hiragana */
78#define LCMAP_KATAKANA 0x00200000 /* map hiragana to katakana */
79#define LCMAP_HALFWIDTH 0x00400000 /* map double byte to single byte */
80#define LCMAP_FULLWIDTH 0x00800000 /* map single byte to double byte */
81
82#define LCMAP_LINGUISTIC_CASING 0x01000000 /* use linguistic rules for casing */
83
84#define LCMAP_SIMPLIFIED_CHINESE 0x02000000 /* map traditional chinese to simplified chinese */
85#define LCMAP_TRADITIONAL_CHINESE 0x04000000 /* map simplified chinese to traditional chinese */
86
87
88
89/*
90 * Locale Enumeration Flags.
91 */
92#define LCID_INSTALLED 0x00000001 /* installed locale ids */
93#define LCID_SUPPORTED 0x00000002 /* supported locale ids */
94
95
96
97// For FindFirstFileEx
98
99#define FIND_FIRST_EX_CASE_SENSITIVE 0x00000001
100
101/*****************************************************************************
102 * Structures *
103 *****************************************************************************/
104
105 // For FindFirstFileEx
106
107typedef enum _FINDEX_INFO_LEVELS {
108 FindExInfoStandard,
109 FindExInfoMaxInfoLevel
110} FINDEX_INFO_LEVELS;
111
112typedef enum _FINDEX_SEARCH_OPS {
113 FindExSearchNameMatch,
114 FindExSearchLimitToDirectories,
115 FindExSearchLimitToDevices,
116 FindExSearchMaxSearchOp
117} FINDEX_SEARCH_OPS;
118
119 // For Backup funtions
120
121typedef struct _WIN32_STREAM_ID {
122
123 DWORD dwStreamId;
124 DWORD dwStreamAttributes;
125 LARGE_INTEGER Size;
126 DWORD dwStreamNameSize;
127// WCHAR cStreamName[ ] ; /* @@@PH */
128 WCHAR cStreamName[1] ;
129} WIN32_STREAM_ID;
130
131
132//
133// File structures
134//
135
136//typedef struct _OVERLAPPED {
137// DWORD Internal;
138// DWORD InternalHigh;
139// DWORD Offset;
140// DWORD OffsetHigh;
141// HANDLE hEvent;
142//} OVERLAPPED, *LPOVERLAPPED;
143
144//typedef struct _SECURITY_ATTRIBUTES {
145// DWORD nLength;
146// LPVOID lpSecurityDescriptor;
147// BOOL bInheritHandle;
148//} SECURITY_ATTRIBUTES, *PSECURITY_ATTRIBUTES, *LPSECURITY_ATTRIBUTES;
149
150//typedef struct _PROCESS_INFORMATION {
151// HANDLE hProcess;
152// HANDLE hThread;
153// DWORD dwProcessId;
154// DWORD dwThreadId;
155//} PROCESS_INFORMATION, *PPROCESS_INFORMATION, *LPPROCESS_INFORMATION;
156
157// For Fiber functions
158
159typedef VOID (WINAPI *PFIBER_START_ROUTINE)(
160 LPVOID lpFiberParameter
161 );
162typedef PFIBER_START_ROUTINE LPFIBER_START_ROUTINE;
163
164// For Enum CalendarInfo & EnumSystemCodePages see winnls.h
165
166/*
167 * Calendar type constant.
168 */
169typedef DWORD CALTYPE;
170
171/*
172 * Calendar ID.
173 */
174typedef DWORD CALID;
175
176
177/*****************************************************************************
178 * Prototypes *
179 *****************************************************************************/
180
181void WIN32API CommonUnimpStub()
182{
183 dprintf(("STUB: KERNEL32.17!!"));
184}
185
186/*****************************************************************************
187 * Name : BOOL WIN32API AreFileApisANSI (VOID)
188 * Purpose : The AreFileApisANSI function determines whether a set of Win32
189 * file functions is using the ANSI or OEM character set code page.
190 * This function is useful for 8-bit console input and output
191 * operations.
192 * Parameters: NONE
193 * Variables :
194 * Result : If the set of Win32 file functions is using the ANSI code page,
195 * the return value is nonzero.
196 * If the set of Win32 file functions is using the OEM code page,
197 * the return value is zero.
198 * Remark :
199 * Status : UNTESTED STUB
200 *
201 * Author : Markus Montkowski [Thu, 1998/02/19 11:46]
202 *****************************************************************************/
203
204BOOL WIN32API AreFileApisANSI (VOID)
205{
206
207 dprintf(("KERNEL32:AreFileApisANSI() not implemented - TRUE\n"
208 ));
209
210 return (TRUE);
211}
212
213/*****************************************************************************
214 * Name : BOOL WIN32API BackupRead(
215 * Purpose : The BackupRead function reads data associated with a specified
216 * file or directory into a buffer. You use this function to back
217 * up a file or directory.
218 * Parameters: HANDLE hFile handle to file or directory
219 * LPBYTE lpBuffer pointer to buffer to read to
220 * DWORD nNumberOfBytesToRead number of bytes to read
221 * LPDWORD lpNumberOfBytesRead pointer to variable to receive
222 * number of bytes read
223 * BOOL bAbort termination type
224 * BOOL bProcessSecurity process security flag
225 * LPVOID *lpContext pointer to pointer to internal
226 * context information
227 * Variables :
228 * Result : 0 on Error Nonzero if OK
229 * Remark : BackupRead processes all of the data pertaining to an opened
230 * object as a series of discrete byte streams. Each stream is
231 * preceded by a 32-bit aligned WIN32_STREAM_ID structure.
232 * Streams must be processed in the same order in which they were
233 * written to the tape. This ordering enables applications to
234 * compare the data backed up against the data on the source device.
235 * The data returned by BackupRead is to be used only as input to
236 * the BackupWrite function. This data is returned as one large data
237 * stream divided into substreams. The substreams are separated
238 * by WIN32_STREAM_ID headers.
239 *
240 * If an error occurs while BackupRead is reading, the calling
241 * process can skip the bad data by calling the BackupSeek function.
242 * Status : UNTESTED STUB
243 *
244 * Author : Markus Montkowski [Thu, 1998/05/19 11:46]
245 *****************************************************************************/
246
247BOOL WIN32API BackupRead(
248 HANDLE hFile, // handle to file or directory
249 LPBYTE lpBuffer, // pointer to buffer to read to
250 DWORD nNumberOfBytesToRead, // number of bytes to read
251 LPDWORD lpNumberOfBytesRead, // pointer to variable to receive number of bytes read
252 BOOL bAbort, // termination type
253 BOOL bProcessSecurity, // process security flag
254 LPVOID *lpContext // pointer to pointer to internal context information
255)
256{
257
258 dprintf(("KERNEL32:BackupRead(%08x,%08x,%08x,%08x,%08x,%08x,%08x) not implemented\n",
259 hFile, lpBuffer, nNumberOfBytesToRead, lpNumberOfBytesRead,
260 bAbort, bProcessSecurity, lpContext
261 ));
262
263 return (FALSE);
264}
265/*****************************************************************************
266 * Name : BOOL WIN32API BackupSeek()
267 * Purpose : The BackupSeek function seeks forward in a data stream initially
268 * accessed by using the BackupRead or BackupWrite function.
269 * Parameters: HANDLE hFile handle to open file
270 * DWORD dwLowBytesToSeek low-order 32 bits of number of bytes
271 * DWORD dwHighBytesToSeek high-order 32 bits of number of bytes
272 * LPDWORD lpdwLowByteSeeked pointer to number of bytes function seeks
273 * LPDWORD lpdwHighByteSeeked pointer to number of bytes function seeks
274 * LPVOID *lpContext pointer to internal context information
275 *
276 * Variables :
277 * Result : If the function could seek the requested amount, the function
278 * returns nonzero.
279 * If the function could not seek the requested amount, the function
280 * returns zero.
281 * Remark : Applications use the BackUpSeek function to skip portions of a
282 * data stream that cause errors. This function does not seek across
283 * stream headers. If an application attempts to seek past the end
284 * of a substream, the function fails, the lpdwLowByteSeeked and
285 * lpdwHighByteSeeked parameters indicate the actual number of bytes
286 * the function seeks, and the file position is placed at the start
287 * of the next stream header.
288 * Status : UNTESTED STUB
289 *
290 * Author : Markus Montkowski [Thu, 1998/05/19 11:46]
291 *****************************************************************************/
292
293BOOL WIN32API BackupSeek( HANDLE hFile, DWORD dwLowBytesToSeek,
294 DWORD dwHighBytesToSeek,
295 LPDWORD lpdwLowByteSeeked,
296 LPDWORD lpdwHighByteSeeked,LPVOID *lpContext)
297{
298
299 dprintf(("KERNEL32:BackupSeek(%08x,%08x,%08x,%08x,%08x,08x) not implemented\n",
300 hFile, dwLowBytesToSeek,dwHighBytesToSeek,
301 lpdwLowByteSeeked, lpdwHighByteSeeked, lpContext));
302
303 return (FALSE);
304}
305
306/*****************************************************************************
307 * Name : BOOL WIN32API BackupWrite
308 * Purpose : The BackupWrite function writes a stream of data from a buffer to
309 * a specified file or directory. The data must be divided into
310 * substreams separated by WIN32_STREAM_ID structures. You use this
311 * function to restore a file or directory that has been backed up.
312 * Parameters: HANDLE hFile handle to file or directory
313 * LPBYTE lpBuffer pointer to buffer containing data
314 * to write
315 * DWORD nNumberOfBytesToWrite number of bytes to write
316 * LPDWORD lpNumberOfBytesWritten pointer to variable to receive
317 * number of bytes written
318 * BOOL bAbort termination type
319 * BOOL bProcessSecurity process security
320 * LPVOID *lpContext pointer to pointer to internal
321 * context information
322 *
323 * Variables :
324 * Result : If the function succeeds, the return value is nonzero.
325 * If the function fails, the return value is zero,
326 * indicating that an I/O error occurred.
327 * To get extended error information, call GetLastError.
328 * Remark :
329 * Status : UNTESTED STUB
330 *
331 * Author : Markus Montkowski [Thu, 1998/05/19 11:46]
332 *****************************************************************************/
333
334BOOL WIN32API BackupWrite( HANDLE hFile, LPBYTE lpBuffer,
335 DWORD nNumberOfBytesToWrite,
336 LPDWORD lpNumberOfBytesWritten,
337 BOOL bAbort, BOOL bProcessSecurity,
338 LPVOID *lpContext)
339{
340
341 dprintf(("KERNEL32:BackupWrite(%08x,%0x8,%08x,%08x,%08x,%08x,%08x) not implemented\n",
342 hFile, lpBuffer, nNumberOfBytesToWrite,
343 lpNumberOfBytesWritten, bAbort, bProcessSecurity, lpContext));
344
345 return (FALSE);
346}
347
348/*****************************************************************************
349 * Name : HANDLE WIN32API BeginUpdateResourceA
350 * Purpose : The BeginUpdateResource function returns a handle that can be
351 * used by the UpdateResource function to add, delete, or replace
352 * resources in an executable file.
353 * Parameters: LPCSTR pFileName pointer to file in which to
354 * update resources
355 * BOOL bDeleteExistingResources deletion option
356 *
357 * Variables :
358 * Result : If the function succeeds, the return value is a handle that can
359 * be used by the UpdateResource and EndUpdateResource functions.
360 * The return value is NULL if the specified file is not an
361 * executable file, the executable file is already loaded,
362 * the file does not exist, or the file cannot be opened for writing.
363 * To get extended error information, call GetLastError
364 * Remark :
365 * Status : UNTESTED STUB
366 *
367 * Author : Markus Montkowski [Thu, 1998/05/19 11:46]
368 *****************************************************************************/
369
370HANDLE WIN32API BeginUpdateResourceA( LPCSTR pFileName,
371 BOOL bDeleteExistingResources)
372{
373
374 dprintf(("KERNEL32: BeginUpdateResource(%08x,%08x) not implemented\n",
375 pFileName, bDeleteExistingResources
376 ));
377
378 return (NULL);
379}
380
381/*****************************************************************************
382 * Name : HANDLE WIN32API BeginUpdateResourceW
383 * Purpose : The BeginUpdateResource function returns a handle that can be
384 * used by the UpdateResource function to add, delete, or replace
385 * resources in an executable file.
386 * Parameters: LPCWSTR pFileName pointer to file in which to
387 * update resources
388 * BOOL bDeleteExistingResources deletion option
389 *
390 * Variables :
391 * Result : If the function succeeds, the return value is a handle that can
392 * be used by the UpdateResource and EndUpdateResource functions.
393 * The return value is NULL if the specified file is not an
394 * executable file, the executable file is already loaded,
395 * the file does not exist, or the file cannot be opened for writing.
396 * To get extended error information, call GetLastError
397 * Remark :
398 * Status : UNTESTED STUB
399 *
400 * Author : Markus Montkowski [Thu, 1998/05/19 11:46]
401 *****************************************************************************/
402
403HANDLE WIN32API BeginUpdateResourceW( LPCWSTR pFileName,
404 BOOL bDeleteExistingResources)
405{
406
407 dprintf(("KERNEL32: BeginUpdateResource(%08x,%08x) not implemented\n",
408 pFileName, bDeleteExistingResources
409 ));
410
411 return (NULL);
412}
413
414/*****************************************************************************
415 * Name : BOOL WIN32API CancelIo
416 * Purpose : The CancelIO function cancels all pending input and output
417 * (I/O) operations that were issued by the calling thread for
418 * the specified file handle. The function does not cancel
419 * I/O operations issued for the file handle by other threads.
420 * Parameters: HANDLE hFile file handle for which to cancel I/O
421 * Variables :
422 * Result : If the function succeeds, the return value is nonzero All pending
423 * I/O operations issued by the calling thread for the file handle
424 * were successfully canceled.
425 * If the function fails, the return value is zero.
426 * To get extended error information, call GetLastError.
427 * Remark : If there are any I/O operations in progress for the specified
428 * file handle, and they were issued by the calling thread, the
429 * CancelIO function cancels them.
430 * Note that the I/O operations must have been issued as
431 * overlapped I/O. If they were not, the I/O operations would not
432 * have returned to allow the thread to call the CancelIO function.
433 * Calling the CancelIO function with a file handle that was not
434 * opened with FILE_FLAG_OVERLAPPED does nothing.
435 * All I/O operations that are canceled will complete with the
436 * error ERROR_OPERATION_ABORTED. All completion notifications
437 * for the I/O operations will occur normally.
438 * Status : UNTESTED STUB
439 *
440 * Author : Markus Montkowski [Thu, 1998/05/19 11:46]
441 *****************************************************************************/
442
443BOOL WIN32API CancelIo(HANDLE hFile)
444{
445
446 dprintf(("KERNEL32:CancelIo(%08x) not implemented\n",
447 hFile
448 ));
449
450 return (FALSE);
451}
452
453/*****************************************************************************
454 * Name : BOOL CancelWaitableTimer
455 * Purpose : The CancelWaitableTimer function sets the specified "waitable"
456 * timer to the inactive state.
457 * Parameters: HANDLE hTimer handle to a timer object
458 * Variables :
459 * Result : If the function succeeds, the return value is nonzero.
460 * If the function fails, the return value is zero.
461 * To get extended error information, call GetLastError.
462 * Remark : The CancelWaitableTimer function does not change the signaled
463 * state of the timer. It stops the timer before it can be set to
464 * the signaled state. Therefore, threads performing a wait
465 * operation on the timer remain waiting until they time out or
466 * the timer is reactivated and its state is set to signaled.
467 *
468 * To reactivate the timer, call the SetWaitableTimer function.
469 * Status : UNTESTED STUB
470 *
471 * Author : Markus Montkowski [Thu, 1998/05/19 11:46]
472 *****************************************************************************/
473
474BOOL WIN32API CancelWaitableTimer(HANDLE hTimer)
475{
476
477 dprintf(("KERNEL32:CancelWaitableTimer(%08x) not implemented\n",
478 hTimer
479 ));
480
481 return (FALSE);
482}
483
484
485/*****************************************************************************
486 * Name : LPVOID WIN32API CreateFiber
487 * Purpose : The CreateFiber function allocates a fiber object, assigns it a
488 * stack, and sets up execution to begin at the specified
489 * start address, typically the fiber function.
490 * This function does not schedule the fiber.
491 * Parameters: DWORD dwStackSize initial thread stack size, in bytes
492 * LPFIBER_START_ROUTINE lpStartAddress pointer to fiber function
493 * LPVOID lpParameter argument for new fiber
494 * Variables :
495 * Result : If the function succeeds, the return value is the address of
496 * the fiber.
497 * If the function fails, the return value is NULL.
498 * Remark : Before a thread can schedule a fiber using the SwitchToFiber
499 * function, it must call the ConvertThreadToFiber function so there
500 * is a fiber associated with the thread.
501 * The fiber function is of type FIBER_START_ROUTINE.
502 * It accepts a single value of type PVOID (fiber data) and does not
503 * return a value. The prototype for this function is as follows:
504 *
505 * VOID WINAPI FiberFunc( PVOID lpParameter );
506 *
507 * Status : UNTESTED STUB
508 *
509 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
510 *****************************************************************************/
511
512LPVOID WIN32API CreateFiber( DWORD dwStackSize,
513 LPFIBER_START_ROUTINE lpStartAddress,
514 LPVOID lpParameter)
515{
516
517 dprintf(("KERNEL32:CreateFiber(%08x,%08x,%08x) not implemented\n",
518 dwStackSize, lpStartAddress,lpParameter
519 ));
520
521 return (NULL);
522}
523
524
525/*****************************************************************************
526 * Name : HANDLE WIN32API CreateIoCompletionPort
527 * Purpose : The CreateIoCompletionPort function can associate an instance of
528 * an opened file with a newly created or an existing input/output
529 * completion port; or it can create an input/output completion port
530 * without associating it with a file.
531 * Associating an instance of an opened file with an input/output
532 * completion port lets an application receive notification of the
533 * completion of asynchronous input/output operations involving that
534 * file.
535 * Parameters: HANDLE FileHandle file handle to associate with I/O
536 * completion port. Must be created
537 * with flag FILE_FLAG_OVERLAPPED !
538 * HANDLE ExistingCompletionPort optional handle to existing
539 * I/O completion port
540 * DWORD CompletionKey per-file completion key for
541 * I/O completion packets
542 * DWORD NumberOfConcurrentThreads number of threads allowed to
543 * execute concurrently
544 * Variables :
545 * Result : If the function succeeds, the return value is the handle to the
546 * I/O completion port that is associated with the specified file.
547 * This return value is not NULL.
548 * If the function fails, the return value is NULL.
549 * Remark : The Win32 I/O system can be instructed to send I/O completion
550 * notification packets to input/output completion ports, where they
551 * are queued up. The CreateIoCompletionPort function provides a
552 * mechanism for this.
553 * When you perform an input/output operation with a file handle
554 * that has an associated input/output completion port, the
555 * I/O system sends a completion notification packet to the
556 * completion port when the I/O operation completes.
557 * The I/O completion port places the completion packet in a
558 * first-in-first-out queue.
559 * Use the GetQueuedCompletionStatus function to retrieve these
560 * queued I/O completion packets.
561 * Threads in the same process can use the PostQueuedCompletionStatus
562 * function to place I/O completion notification packets in a
563 * completion port's queue. This allows you to use the port to
564 * receive communications from other threads of the process,
565 * in addition to receiving I/O completion notification packets
566 * from the Win32 I/O system.
567 * Status : UNTESTED STUB
568 *
569 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
570 *****************************************************************************/
571
572HANDLE WIN32API CreateIoCompletionPort( HANDLE FileHandle,
573 HANDLE ExistingCompletionPort,
574 DWORD CompletionKey,
575 DWORD NumberOfConcurrentThreads)
576{
577
578 dprintf(("KERNEL32: CreateIoCompletionPort(%08x,%08x,%08x,%08x) not implemented\n",
579 FileHandle, ExistingCompletionPort, CompletionKey,
580 NumberOfConcurrentThreads
581 ));
582
583 return (NULL);
584}
585/*****************************************************************************
586 * Name : HANDLE WIN32API CreateMailslotA
587 * Purpose : The CreateMailslot function creates a mailslot with the specified
588 * name and returns a handle that a mailslot server can use to
589 * perform operations on the mailslot. The mailslot is local to the
590 * computer that creates it. An error occurs if a mailslot with
591 * the specified name already exists.
592 * Parameters: LPCSTR lpName pointer to string for mailslot name
593 * DWORD nMaxMessageSize maximum message size
594 * DWORD lReadTimeout milliseconds before read time-out
595 * LPSECURITY_ATTRIBUTES lpSecurityAttributes pointer to security structure
596 * Variables :
597 * Result : If the function succeeds, the return value is a handle to
598 * the mailslot, for use in server mailslot operations.
599 * If the function fails, the return value is INVALID_HANDLE_VALUE.
600 * Remark :
601 * Status : UNTESTED STUB
602 *
603 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
604 *****************************************************************************/
605
606HANDLE WIN32API CreateMailslotA(LPCSTR lpName, DWORD nMaxMessageSize,
607 DWORD lReadTimeout,
608 LPSECURITY_ATTRIBUTES lpSecurityAttributes)
609{
610
611 dprintf(("KERNEL32: CreateMailslotA(%08x,%08x,%08x,%08x) not implemented - INVALID_HANDLE_VALUE\n",
612 lpName, nMaxMessageSize, lReadTimeout, lpSecurityAttributes
613 ));
614
615 return (INVALID_HANDLE_VALUE);
616}
617
618/*****************************************************************************
619 * Name : HANDLE WIN32API CreateMailslotW
620 * Purpose : The CreateMailslot function creates a mailslot with the specified
621 * name and returns a handle that a mailslot server can use to
622 * perform operations on the mailslot. The mailslot is local to the
623 * computer that creates it. An error occurs if a mailslot with
624 * the specified name already exists.
625 * Parameters: LPCWSTR lpName pointer to string for mailslot name
626 * DWORD nMaxMessageSize maximum message size
627 * DWORD lReadTimeout milliseconds before read time-out
628 * LPSECURITY_ATTRIBUTES lpSecurityAttributes pointer to security
629 * structure
630 * Variables :
631 * Result : If the function succeeds, the return value is a handle to
632 * the mailslot, for use in server mailslot operations.
633 * If the function fails, the return value is INVALID_HANDLE_VALUE.
634 * Remark :
635 * Status : UNTESTED STUB
636 *
637 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
638 *****************************************************************************/
639
640HANDLE WIN32API CreateMailslotW(LPCWSTR lpName, DWORD nMaxMessageSize,
641 DWORD lReadTimeout,
642 LPSECURITY_ATTRIBUTES lpSecurityAttributes)
643{
644
645 dprintf(("KERNEL32: CreateMailslotW(%08x,%08x,%08x,%08x) not implemented - INVALID_HANDLE_VALUE\n",
646 lpName, nMaxMessageSize, lReadTimeout, lpSecurityAttributes
647 ));
648
649 return (INVALID_HANDLE_VALUE);
650}
651
652/*****************************************************************************
653 * Name : HANDLE WIN32API CreateRemoteThread
654 * Purpose : The CreateRemoteThread function creates a thread that runs in
655 * the address space of another process.
656 * Parameters: HANDLE hProcess handle to process to create thread in
657 * LPSECURITY_ATTRIBUTES lpThreadAttributes pointer to thread
658 * security attributes
659 * DWORD dwStackSize initial thread stack size, in bytes
660 * LPTHREAD_START_ROUTINE lpStartAddress pointer to thread function
661 * LPVOID lpParameter pointer to argument for new thread
662 * DWORD dwCreationFlags creation flags
663 * LPDWORD lpThreadId pointer to returned thread identifier
664 * Variables :
665 * Result : If the function succeeds, the return value is a handle to
666 * the new thread.
667 * If the function fails, the return value is NULL.
668 * Remark :
669 * Status : UNTESTED STUB
670 *
671 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
672 *****************************************************************************/
673
674HANDLE WIN32API CreateRemoteThread( HANDLE hProcess,
675 LPSECURITY_ATTRIBUTES lpThreadAttributes,
676 DWORD dwStackSize,
677 LPTHREAD_START_ROUTINE lpStartAddress,
678 LPVOID lpParameter,DWORD dwCreationFlags,
679 LPDWORD lpThreadId )
680{
681
682 dprintf(("KERNEL32: CreateRemoteThread(%08x,%08x,%08x,%08x,%08x,%08x,%08x) not implemented\n",
683 hProcess, lpThreadAttributes, dwStackSize, lpStartAddress,
684 lpParameter, dwCreationFlags, lpThreadId
685 ));
686
687 return (NULL);
688}
689/*****************************************************************************
690 * Name : DWORD WIN32API CreateTapePartition
691 * Purpose : The CreateTapePartition function reformats a tape.
692 * Parameters: HANDLE hDevice handle to open device
693 * DWORD dwPartitionMethode type of new partition
694 * DWORD dwCount number of new partitions to create
695 * DWORD dwSize size of new partition, in megabytes
696 * Variables :
697 * Result : If the function succeeds, the return value is NO_ERROR.
698 * If the function fails, it may return one of the following
699 * error codes:
700 * Error Description
701 * ERROR_BEGINNING_OF_MEDIA An attempt to access data before
702 * the beginning-of-medium marker failed.
703 * ERROR_BUS_RESET A reset condition was detected on the bus.
704 * ERROR_END_OF_MEDIA The end-of-tape marker was reached
705 * during an operation.
706 * ERROR_FILEMARK_DETECTED A filemark was reached during an operation.
707 * ERROR_SETMARK_DETECTED A setmark was reached during an operation.
708 * ERROR_NO_DATA_DETECTED The end-of-data marker was reached
709 * during an operation.
710 * ERROR_PARTITION_FAILURE The tape could not be partitioned.
711 * ERROR_INVALID_BLOCK_LENGTH The block size is incorrect on a
712 * new tape in a multivolume partition.
713 * ERROR_DEVICE_NOT_PARTITIONED The partition information could not
714 * be found when a tape was being loaded.
715 * ERROR_MEDIA_CHANGED The tape that was in the drive has
716 * been replaced or removed.
717 * ERROR_NO_MEDIA_IN_DRIVE There is no media in the drive.
718 * ERROR_NOT_SUPPORTED The tape driver does not support a
719 * requested function.
720 * ERROR_UNABLE_TO_LOCK_MEDIA An attempt to lock the ejection
721 * mechanism failed.
722 * ERROR_UNABLE_TO_UNLOAD_MEDIA An attempt to unload the tape failed.
723 * ERROR_WRITE_PROTECT The media is write protected.
724 * Remark : Creating partitions reformats the tape. All previous information
725 * recorded on the tape is destroyed.
726 * Errorcodes are defined in winerror.h
727 * Status : UNTESTED STUB
728 *
729 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
730 *****************************************************************************/
731
732DWORD WIN32API CreateTapePartition( HANDLE hDevice, DWORD dwPartitionMethod,
733 DWORD dwCount, DWORD dwSize)
734{
735
736 dprintf(("KERNEL32: CreateTapePartition(%08x,%08x,%08x,%08x) not implemented - ERROR_NOT_SUPPORTED\n",
737 hDevice, dwPartitionMethod, dwCount, dwSize
738 ));
739
740 return (ERROR_NOT_SUPPORTED);
741}
742/*****************************************************************************
743 * Name : HANDLE WIN23API CreateWaitableTimerA
744 * Purpose : The CreateWaitableTimerA function creates a "waitable" timer object.
745 * Parameters: LPSECURITY_ATTRIBUTES lpTimerAttributes pointer to security attributes
746 * BOOL bManualReset flag for manual reset state
747 * LPCTSTR lpTimerName pointer to timer object name
748 * Variables :
749 * Result : If the function succeeds, the return value is a handle to the
750 * timer object. If the named timer object exists before the
751 * function call, GetLastError returns ERROR_ALREADY_EXISTS.
752 * Otherwise, GetLastError returns zero.
753 * If the function fails, the return value is NULL
754 * Remark :
755 * Status : UNTESTED STUB
756 *
757 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
758 *****************************************************************************/
759
760HANDLE WIN32API CreateWaitableTimerA( LPSECURITY_ATTRIBUTES lpTimerAttributes,
761 BOOL bManualReset, LPCSTR lpTimerName)
762{
763
764 dprintf(("KERNEL32: CreateWaitableTimer(%08x,%08x,%08x) not implemented\n",
765 lpTimerAttributes, bManualReset, lpTimerName
766 ));
767
768 return (NULL);
769}
770
771/*****************************************************************************
772 * Name : HANDLE WIN23API CreateWaitableTimerW
773 * Purpose : The CreateWaitableTimerW function creates a "waitable" timer object.
774 * Parameters: LPSECURITY_ATTRIBUTES lpTimerAttributes pointer to security attributes
775 * BOOL bManualReset flag for manual reset state
776 * LPCTSTR lpTimerName pointer to timer object name
777 * Variables :
778 * Result : If the function succeeds, the return value is a handle to the
779 * timer object. If the named timer object exists before the
780 * function call, GetLastError returns ERROR_ALREADY_EXISTS.
781 * Otherwise, GetLastError returns zero.
782 * If the function fails, the return value is NULL
783 * Remark :
784 * Status : UNTESTED STUB
785 *
786 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
787 *****************************************************************************/
788
789HANDLE WIN32API CreateWaitableTimerW( LPSECURITY_ATTRIBUTES lpTimerAttributes,
790 BOOL bManualReset, LPCWSTR lpTimerName)
791{
792
793 dprintf(("KERNEL32: CreateWaitableTimer(%08x,%08x,%08x) not implemented\n",
794 lpTimerAttributes, bManualReset, lpTimerName
795 ));
796
797 return (NULL);
798}
799
800/*****************************************************************************
801 * Name : BOOL WIN32API DebugActiveProcess
802 * Purpose : The DebugActiveProcess function allows a debugger to attach to
803 * an active process and then debug it.
804 * Parameters: DWORD dwProcessId process to be debugged
805 * Variables :
806 * Result : If the function succeeds, the return value is nonzero.
807 * If the function fails, the return value is zero
808 * Remark :
809 * Status : UNTESTED STUB
810 *
811 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
812 *****************************************************************************/
813
814BOOL WIN32API DebugActiveProcess(DWORD dwProcessId)
815{
816
817 dprintf(("KERNEL32:DebugActiveProcess(%08x) not implemented\n",
818 dwProcessId
819 ));
820
821 return (FALSE);
822}
823
824/*****************************************************************************
825 * Name : BOOL WIN32API DefineDosDeviceA
826 * Purpose : The DefineDosDeviceA function lets an application define,
827 * redefine, or delete MS-DOS device names.
828 * MS-DOS device names are stored as symbolic links in the object
829 * name space in 32-bit versions of Windows. The code that converts
830 * an MS-DOS path into a corresponding path in 32-bit versions of
831 * Windows uses these symbolic links to map MS-DOS devices and drive
832 * letters. The DefineDosDevice function provides a mechanism
833 * whereby a Win32-based application can modify the symbolic links
834 * used to implement the MS-DOS device name space.
835 * Parameters: DWORD dwFlags flags specifying aspects of device definition
836 * LPCSTR lpDeviceName pointer to MS-DOS device name string
837 * LPCSTR lpTargetPath pointer to MS-DOS or path string for
838 * 32-bit Windows
839 * Variables :
840 * Result : If the function succeeds, the return value is nonzero.
841 * If the function fails, the return value is zero
842 * Remark :
843 * Status : UNTESTED STUB
844 *
845 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
846 *****************************************************************************/
847
848BOOL WIN32API DefineDosDeviceA( DWORD dwFlags, LPCSTR lpDeviceName,
849 LPCSTR lpTargetPath )
850{
851
852 dprintf(("KERNEL32: DefineDosDeviceA(%08x,%08x,%08x) not implemented\n",
853 dwFlags, lpDeviceName, lpTargetPath
854 ));
855
856 return (FALSE);
857}
858
859/*****************************************************************************
860 * Name : BOOL WIN32API DefineDosDeviceW
861 * Purpose : UNICODE version of DefineDosDeviceA
862 * Parameters: DWORD dwFlags flags specifying aspects of device definition
863 * LPCSTR lpDeviceName pointer to MS-DOS device name string
864 * LPCSTR lpTargetPath pointer to MS-DOS or path string for
865 * 32-bit Windows
866 * Variables :
867 * Result : If the function succeeds, the return value is nonzero.
868 * If the function fails, the return value is zero
869 * Remark :
870 * Status : UNTESTED STUB
871 *
872 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
873 *****************************************************************************/
874
875BOOL WIN32API DefineDosDeviceW( DWORD dwFlags, LPCWSTR lpDeviceName,
876 LPCWSTR lpTargetPath )
877{
878
879 dprintf(("KERNEL32: DefineDosDeviceW(%08x,%08x,%08x) not implemented\n",
880 dwFlags, lpDeviceName, lpTargetPath
881 ));
882
883 return (FALSE);
884}
885
886/*****************************************************************************
887 * Name : VOID WIN32API DeleteFiber
888 * Purpose : The DeleteFiber function deletes an existing fiber
889 * Parameters: LPVOID lpFiber pointer to the fiber to delete
890 * Variables :
891 * Result : No returnvalue
892 * Remark : The DeleteFiber function deletes all data associated with the
893 * fiber. This data includes the stack, a subset of the registers,
894 * and the fiber data. If the currently running fiber calls
895 * DeleteFiber, the ExitThread function is called and the thread
896 * terminates. If the currently running fiber is deleted by another
897 * thread, the thread associated with the fiber is likely to
898 * terminate abnormally because the fiber stack has been freed.
899 * Status : UNTESTED STUB
900 *
901 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
902 *****************************************************************************/
903
904VOID WIN32API DeleteFiber(LPVOID lpFiber)
905{
906
907 dprintf(("KERNEL32: DeleteFiber(%08x) not implemented\n",
908 lpFiber
909 ));
910}
911/*****************************************************************************
912 * Name : BOOL WIN3API EndUpdateResourceA
913 * Purpose : The EndUpdateResourceA function ends a resource update
914 * in an executable file.
915 * Parameters: HANDLE hUpdate update-file handle
916 * BOOL fDiscard write flag
917 * Variables :
918 * Result : If the function succeeds and the accumulated resource
919 * modifications specified by calls to the UpdateResource function
920 * are written to the specified executable file,
921 * the return value is nonzero.
922 * If the function fails, the return value is zero
923 * Remark :
924 * Status : UNTESTED STUB
925 *
926 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
927 *****************************************************************************/
928
929BOOL WIN32API EndUpdateResourceA(HANDLE hUpdate,BOOL fDiscard)
930{
931
932 dprintf(("KERNEL32:EndUpdateResourceA(%08x,%08x)not implemented\n",
933 hUpdate, fDiscard
934 ));
935
936 return (FALSE);
937}
938
939/*****************************************************************************
940 * Name : BOOL WIN3API EndUpdateResourceW
941 * Purpose : The EndUpdateResourceW function ends a resource update
942 * in an executable file.
943 * Parameters: HANDLE hUpdate update-file handle
944 * BOOL fDiscard write flag
945 * Variables :
946 * Result : If the function succeeds and the accumulated resource
947 * modifications specified by calls to the UpdateResource function
948 * are written to the specified executable file,
949 * the return value is nonzero.
950 * If the function fails, the return value is zero
951 * Remark :
952 * Status : UNTESTED STUB
953 *
954 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
955 *****************************************************************************/
956
957BOOL WIN32API EndUpdateResourceW(HANDLE hUpdate,BOOL fDiscard)
958{
959
960 dprintf(("KERNEL32:EndUpdateResourceW(%08x,%08x) not implemented\n",
961 hUpdate, fDiscard
962 ));
963
964 return (FALSE);
965}
966
967
968/*****************************************************************************
969 * Name : BOOL WIN32API EnumSystemCodePagesA
970 * Purpose : The EnumSystemCodePagesA function enumerates the code pages that
971 * are either installed on or supported by a system. The dwFlags
972 * parameter determines whether the function enumerates installed
973 * or supported code pages. The function enumerates the code pages
974 * by passing code page identifiers, one at a time, to the specified
975 * application-defined callback function. This continues until all
976 * of the installed or supported code page identifiers have been
977 * passed to the callback function, or the callback function
978 * returns FALSE
979 * Parameters: CODEPAGE_ENUMPROCA lpCodePageEnumProc pointer to enumeration
980 * callback function
981 * DWORD dwFlags indicates which code pages
982 * to enumerate
983 * Variables :
984 * Result : If the function succeeds, the return value is nonzero.
985 * If the function fails, the return value is zero
986 * Remark :
987 * Status : UNTESTED STUB
988 *
989 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
990 *****************************************************************************/
991
992BOOL WIN32API EnumSystemCodePagesA(CODEPAGE_ENUMPROCA lpCodePageEnumProc,
993 DWORD dwFlags)
994{
995
996 dprintf(("KERNEL32: EnumSystemCodePagesA(%08x,%08x) not implemented\n",
997 lpCodePageEnumProc, dwFlags
998 ));
999
1000 return (FALSE);
1001}
1002
1003/*****************************************************************************
1004 * Name : BOOL WIN32API EnumSystemCodePagesW
1005 * Purpose : The EnumSystemCodePagesW function enumerates the code pages that
1006 * are either installed on or supported by a system. The dwFlags
1007 * parameter determines whether the function enumerates installed
1008 * or supported code pages. The function enumerates the code pages
1009 * by passing code page identifiers, one at a time, to the specified
1010 * application-defined callback function. This continues until all
1011 * of the installed or supported code page identifiers have been
1012 * passed to the callback function, or the callback function
1013 * returns FALSE
1014 * Parameters: CODEPAGE_ENUMPROCW lpCodePageEnumProc pointer to enumeration
1015 * callback function
1016 * DWORD dwFlags indicates which code pages
1017 * to enumerate
1018 * Variables :
1019 * Result : If the function succeeds, the return value is nonzero.
1020 * If the function fails, the return value is zero
1021 * Remark :
1022 * Status : UNTESTED STUB
1023 *
1024 * Author : Markus Montkowski [Tha, 1998/05/21 17:46]
1025 *****************************************************************************/
1026
1027BOOL WIN32API EnumSystemCodePagesW(CODEPAGE_ENUMPROCW lpCodePageEnumProc,
1028 DWORD dwFlags)
1029{
1030
1031 dprintf(("KERNEL32: EnumSystemCodePagesA(%08x,%08x) not implemented\n",
1032 lpCodePageEnumProc, dwFlags
1033 ));
1034
1035 return (FALSE);
1036}
1037
1038/*****************************************************************************
1039 * Name : DWORD WIN32API EraseTape
1040 * Purpose : The EraseTape function erases all or part of a tape.
1041 * Parameters: HANDLE hDevice handle to open device
1042 * DWORD dwEraseType type of erasure to perform
1043 * BOOL bImmediate return after erase operation begins
1044 * Variables :
1045 * Result : If the function succeeds, the return value is NO_ERROR.
1046 * If the function fails, the return value is like in
1047 * CreateTapePartition
1048 * Remark : Some tape devices do not support certain tape operations. To de
1049 * termine your tape device's capabilities, see your tape device
1050 * documentation and use the GetTapeParameters function
1051 * Status : UNTESTED STUB
1052 *
1053 * Author : Markus Montkowski [Tha, 1998/05/21 20:57]
1054 *****************************************************************************/
1055
1056DWORD WIN32API EraseTape( HANDLE hDevice, DWORD dwEraseType, BOOL bImmediate)
1057{
1058
1059 dprintf(("KERNEL32: EraseTape(%08x,%08x,%08x) not implemented - ERROR_NOT_SUPPORTED\n",
1060 hDevice, dwEraseType, bImmediate
1061 ));
1062
1063 return (ERROR_NOT_SUPPORTED);
1064}
1065
1066
1067/*****************************************************************************
1068 * Name : HANDLE WIN32API FindFirstFileExA
1069 * Purpose : The FindFirstFileExA function searches a directory for a file
1070 * whose name and attributes match those specified in the
1071 * function call.
1072 * Parameters: LPCSTR lpFileName pointer to the name of the file
1073 * to search for
1074 * FINDEX_INFO_LEVELS fInfoLevelId information level of the returned data
1075 * LPVOID lpFindFileData pointer to the returned information
1076 * FINDEX_SEARCH_OPS fSearchOp type of filtering to perform
1077 * LPVOID lpSearchFilter pointer to search criteria
1078 * DWORD dwAdditionalFlags additional search control flags
1079 * Variables :
1080 * Result : If the function succeeds, the return value is a search handle
1081 * that can be used in a subsequent call to the FindNextFile or
1082 * FindClose functions.
1083 * If the function fails, the return value is INVALID_HANDLE_VALUE
1084 * Remark :
1085 * Status : UNTESTED STUB
1086 *
1087 * Author : Markus Montkowski [Tha, 1998/05/21 20:57]
1088 *****************************************************************************/
1089
1090HANDLE WIN32API FindFirstFileExA( LPCSTR lpFileName,
1091 FINDEX_INFO_LEVELS fInfoLevelId,
1092 LPVOID lpFindFileData,
1093 FINDEX_SEARCH_OPS fSearchOp,
1094 LPVOID lpSearchFilter,
1095 DWORD dwAdditionalFlags)
1096{
1097
1098 dprintf(("KERNEL32: FindFirstFileExA(%08x,%08x,%08x,%08x,%08x,%08x)not implemented - INVALID_HANDLE_VALUE\n",
1099 lpFileName,
1100 fInfoLevelId,
1101 lpFindFileData,
1102 fSearchOp,
1103 lpSearchFilter,
1104 dwAdditionalFlags
1105 ));
1106
1107 return (INVALID_HANDLE_VALUE);
1108}
1109
1110/*****************************************************************************
1111 * Name : HANDLE WIN32API FindFirstFileExW
1112 * Purpose : The FindFirstFileExW function searches a directory for a file
1113 * whose name and attributes match those specified in the
1114 * function call.
1115 * Parameters: LPCWSTR lpFileName pointer to the name of the file
1116 * to search for
1117 * FINDEX_INFO_LEVELS fInfoLevelId information level of the returned data
1118 * LPVOID lpFindFileData pointer to the returned information
1119 * FINDEX_SEARCH_OPS fSearchOp type of filtering to perform
1120 * LPVOID lpSearchFilter pointer to search criteria
1121 * DWORD dwAdditionalFlags additional search control flags
1122 * Variables :
1123 * Result : If the function succeeds, the return value is a search handle
1124 * that can be used in a subsequent call to the FindNextFile or
1125 * FindClose functions.
1126 * If the function fails, the return value is INVALID_HANDLE_VALUE
1127 * Remark :
1128 * Status : UNTESTED STUB
1129 *
1130 * Author : Markus Montkowski [Tha, 1998/05/21 20:57]
1131 *****************************************************************************/
1132
1133HANDLE WIN32API FindFirstFileExW( LPCWSTR lpFileName,
1134 FINDEX_INFO_LEVELS fInfoLevelId,
1135 LPVOID lpFindFileData,
1136 FINDEX_SEARCH_OPS fSearchOp,
1137 LPVOID lpSearchFilter,
1138 DWORD dwAdditionalFlags)
1139{
1140
1141 dprintf(("KERNEL32: FindFirstFileExW(%08x,%08x,%08x,%08x,%08x,%08x)not implemented - INVALID_HANDLE_VALUE\n",
1142 lpFileName,
1143 fInfoLevelId,
1144 lpFindFileData,
1145 fSearchOp,
1146 lpSearchFilter,
1147 dwAdditionalFlags
1148 ));
1149
1150 return (INVALID_HANDLE_VALUE);
1151}
1152
1153/*****************************************************************************
1154 * Name : int WIN32API FoldStringA
1155 * Purpose : The FoldStringW function maps one string to another, performing
1156 * a specified transformation option.
1157 * Parameters: DWORD dwMapFlags, // mapping transformation options
1158 * LPCSTR lpSrcStr, // pointer to source string
1159 * int cchSrc, // size of source string, in bytes or characters
1160 * LPSTR lpDestStr, // pointer to destination buffer
1161 * int cchDest // size of destination buffer, in bytes or characters
1162 * Variables :
1163 * Result : If the function succeeds, the return value is the number of bytes
1164 * (ANSI version) or characters (Unicode version) written to the
1165 * destination buffer, or if the cchDest parameter is zero,
1166 * the number of bytes or characters required to hold the mapped
1167 * string.
1168 * If the function fails, the return value is zero
1169 * Remark :
1170 * Status : UNTESTED STUB
1171 *
1172 * Author : Markus Montkowski [Tha, 1998/05/21 20:57]
1173 *****************************************************************************/
1174
1175int WIN32API FoldStringA( DWORD dwMapFlags, LPCSTR lpSrcStr,
1176 int cchSrc, LPSTR lpDestStr, int cchDest)
1177{
1178
1179 dprintf(("KERNEL32: FoldStringA(%08x,%08x,%08x,%08x,%08x) not implemented\n",
1180 dwMapFlags, lpSrcStr, cchSrc, lpDestStr, cchDest
1181 ));
1182
1183 return (0);
1184}
1185
1186/*****************************************************************************
1187 * Name : int WIN32API FoldStringW
1188 * Purpose : The FoldStringW function maps one string to another, performing
1189 * a specified transformation option.
1190 * Parameters: DWORD dwMapFlags, // mapping transformation options
1191 * LPCSTR lpSrcStr, // pointer to source string
1192 * int cchSrc, // size of source string, in bytes or characters
1193 * LPSTR lpDestStr, // pointer to destination buffer
1194 * int cchDest // size of destination buffer, in bytes or characters
1195 * Variables :
1196 * Result : If the function succeeds, the return value is the number of bytes
1197 * (ANSI version) or characters (Unicode version) written to the
1198 * destination buffer, or if the cchDest parameter is zero,
1199 * the number of bytes or characters required to hold the mapped
1200 * string.
1201 * If the function fails, the return value is zero
1202 * Remark :
1203 * Status : UNTESTED STUB
1204 *
1205 * Author : Markus Montkowski [Tha, 1998/05/21 20:57]
1206 *****************************************************************************/
1207
1208int WIN32API FoldStringW( DWORD dwMapFlags, LPCWSTR lpSrcStr,
1209 int cchSrc, LPWSTR lpDestStr, int cchDest)
1210{
1211
1212 dprintf(("KERNEL32: FoldStringA(%08x,%08x,%08x,%08x,%08x) not implemented\n",
1213 dwMapFlags, lpSrcStr, cchSrc, lpDestStr, cchDest
1214 ));
1215
1216 return (0);
1217}
1218
1219
1220/*****************************************************************************
1221 * Name : VOID WIN32API FreeLibraryAndExitThread
1222 * Purpose : The FreeLibraryAndExitThread function decrements the reference
1223 * count of a loaded dynamic-link library (DLL) by one, and then
1224 * calls ExitThread to terminate the calling thread.
1225 * The function does not return.
1226 *
1227 * The FreeLibraryAndExitThread function gives threads that are
1228 * created and executed within a dynamic-link library an opportunity
1229 * to safely unload the DLL and terminate themselves.
1230 * Parameters:
1231 * Variables :
1232 * Result :
1233 * Remark :
1234 * Status : UNTESTED STUB
1235 *
1236 * Author : Markus Montkowski [Tha, 1998/05/21 20:57]
1237 *****************************************************************************/
1238
1239VOID WIN32API FreeLibraryAndExitThread( HMODULE hLibModule, DWORD dwExitCode)
1240{
1241
1242 dprintf(("KERNEL32: FreeLibraryAndExitThread(%08x,%08x) not implemented\n",
1243 hLibModule, dwExitCode
1244 ));
1245
1246}
1247
1248
1249/*****************************************************************************
1250 * Name : DWORD GetHandleInformation
1251 * Purpose : The GetHandleInformation function obtains information about certain
1252 * properties of an object handle. The information is obtained as a set of bit flags.
1253 * Parameters: HANDLE hObject
1254 * LPDWORD lpdwFlags
1255 * Variables :
1256 * Result : TRUE / FALSE
1257 * Remark :
1258 * Status : UNTESTED STUB
1259 *
1260 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1261 *****************************************************************************/
1262
1263BOOL WIN32API GetHandleInformation(HANDLE hObject,
1264 LPDWORD lpdwFlags)
1265{
1266 dprintf(("KERNEL32: GetHandleInformation (%08xh, %08xh) not implemented\n",
1267 hObject,
1268 lpdwFlags));
1269
1270 return (FALSE);
1271}
1272
1273
1274/*****************************************************************************
1275 * Name : BOOL GetMailslotInfo
1276 * Purpose : The GetMailslotInfo function retrieves information about the
1277 * specified mailslot.
1278 * Parameters: HANDLE hMailslot mailslot handle
1279 * LPDWORD lpMaxMessageSize address of maximum message size
1280 * LPDWORD lpNextSize address of size of next message
1281 * LPDWORD lpMessageCount address of number of messages
1282 * LPDWORD lpReadTimeout address of read time-out
1283 * Variables :
1284 * Result : TRUE / FALSE
1285 * Remark :
1286 * Status : UNTESTED STUB
1287 *
1288 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1289 *****************************************************************************/
1290
1291BOOL WIN32API GetMailslotInfo(HANDLE hMailslot,
1292 LPDWORD lpMaxMessageSize,
1293 LPDWORD lpNextSize,
1294 LPDWORD lpMessageCount,
1295 LPDWORD lpReadTimeout)
1296{
1297 dprintf(("KERNEL32: GetMailslotInfo(%08xh,%08xh,%08xh,%08xh,%08xh) not implemented\n",
1298 hMailslot,
1299 lpMaxMessageSize,
1300 lpNextSize,
1301 lpMessageCount,
1302 lpReadTimeout));
1303
1304 return (FALSE);
1305}
1306
1307
1308
1309/*****************************************************************************
1310 * Name : BOOL GetQueuedCompletionStatus
1311 * Purpose : The GetQueuedCompletionStatus function attempts to dequeue an
1312 * I/O completion packet from a specified input/output completion
1313 * port. If there is no completion packet queued, the function waits
1314 * for a pending input/output operation associated with the completion
1315 * port to complete. The function returns when it can dequeue a
1316 * completion packet, or optionally when the function times out. If
1317 * the function returns because of an I/O operation completion, it
1318 * sets several variables that provide information about the operation.
1319 * Parameters: HANDLE CompletionPort the I/O completion port of interest
1320 * LPDWORD lpNumberOfBytesTransferred to receive number of bytes transferred during I/O
1321 * LPDWORD lpCompletionKey to receive file's completion key
1322 * LPOVERLAPPED * lpOverlapped to receive pointer to OVERLAPPED structure
1323 * DWORD dwMilliseconds optional timeout value
1324 * Variables :
1325 * Result : TRUE / FALSE
1326 * Remark :
1327 * Status : UNTESTED STUB
1328 *
1329 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1330 *****************************************************************************/
1331
1332BOOL WIN32API GetQueuedCompletionStatus(HANDLE CompletionPort,
1333 LPDWORD lpNumberOfBytesTransferred,
1334 LPDWORD lpCompletionKey,
1335 LPOVERLAPPED *lpOverlapped,
1336 DWORD dwMilliseconds)
1337{
1338 dprintf(("Kernel32: GetQueuedCompletionStatus(%08xh,%08xh,%08xh,%08xh,%08xh) not implemented.",
1339 CompletionPort,
1340 lpNumberOfBytesTransferred,
1341 lpCompletionKey,
1342 lpOverlapped,
1343 dwMilliseconds));
1344
1345 return (FALSE);
1346}
1347
1348
1349
1350/*****************************************************************************
1351 * Name : BOOL GetSystemTimeAdjustment
1352 * Purpose : The GetSystemTimeAdjustment function determines whether the system
1353 * is applying periodic time adjustments to its time-of-day clock
1354 * at each clock interrupt, along with the value and period of any
1355 * such adjustments. Note that the period of such adjustments is
1356 * equivalent to the time period between clock interrupts.
1357 * Parameters: PDWORD lpTimeAdjustment
1358 * size, in 100-nanosecond units, of a periodic time adjustment
1359 * PDWORD lpTimeIncrement
1360 * time, in 100-nanosecond units, between periodic time adjustments
1361 * PBOOL lpTimeAdjustmentDisabled
1362 * whether periodic time adjustment is disabled or enabled
1363 * Variables :
1364 * Result : TRUE / FALSE
1365 * Remark :
1366 * Status : UNTESTED STUB
1367 *
1368 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1369 *****************************************************************************/
1370
1371BOOL WIN32API GetSystemTimeAdjustment(PDWORD lpTimeAdjustment,
1372 PDWORD lpTimeIncrement,
1373 PBOOL lpTimeAdjustmentDisabled)
1374{
1375 dprintf(("KERNEL32: GetSystemTimeAdjustment(%08xh,%08xh,%08xh) not implemented.\n",
1376 lpTimeAdjustment,
1377 lpTimeIncrement,
1378 lpTimeAdjustmentDisabled));
1379
1380 return (FALSE);
1381}
1382
1383
1384/*****************************************************************************
1385 * Name : BOOL GetTapeParameters
1386 * Purpose : The GetTapeParameters function retrieves information that
1387 * describes the tape or the tape drive.
1388 * Parameters: HANDLE hDevice handle of open device
1389 * DWORD dwOperation type of information requested
1390 * LPDWORD lpdwSize address of returned information
1391 * LPVOID lpTapeInformation tape media or drive information
1392 * Variables :
1393 * Result : API returncode
1394 * Remark :
1395 * Status : UNTESTED STUB
1396 *
1397 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1398 *****************************************************************************/
1399
1400DWORD WIN32API GetTapeParameters(HANDLE hDevice,
1401 DWORD dwOperation,
1402 LPDWORD lpdwSize,
1403 LPVOID lpTapeInformation)
1404{
1405 dprintf(("KERNEL32: GetTapeParameters(%08xh,%08xh,%08xh,%08xh) not implemented - ERROR_NOT_SUPPORTED.\n",
1406 hDevice,
1407 dwOperation,
1408 lpdwSize,
1409 lpTapeInformation));
1410
1411 return (ERROR_NOT_SUPPORTED);
1412}
1413
1414
1415/*****************************************************************************
1416 * Name : BOOL GetTapePosition
1417 * Purpose : The GetTapePosition function retrieves the current address of
1418 * the tape, in logical or absolute blocks.
1419 * Parameters: HANDLE hDevice handle of open device
1420 * DWORD dwPositionType type of address to obtain
1421 * LPDWORD lpdwPartition address of current tape partition
1422 * LPDWORD lpdwOffsetLow address of low-order 32 bits of tape position
1423 * LPDWORD lpdwOffsetHigh address of high-order 32 bits of tape position
1424 * Variables :
1425 * Result : TRUE / FALSE
1426 * Remark :
1427 * Status : UNTESTED STUB
1428 *
1429 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1430 *****************************************************************************/
1431
1432DWORD WIN32API GetTapePosition(HANDLE hDevice,
1433 DWORD dwPositionType,
1434 LPDWORD lpdwPartition,
1435 LPDWORD lpdwOffsetLow,
1436 LPDWORD lpdwOffsetHigh)
1437{
1438 dprintf(("KERNEL32: OS2GetTapePosition(%08xh,%08xh,%08xh,%08xh,%08xh) not implemented - ERROR_NOT_SUPPORTED.\n",
1439 hDevice,
1440 dwPositionType,
1441 lpdwPartition,
1442 lpdwOffsetLow,
1443 lpdwOffsetHigh));
1444
1445 return (ERROR_NOT_SUPPORTED);
1446}
1447
1448
1449/*****************************************************************************
1450 * Name : BOOL GetTapeStatus
1451 * Purpose : The GetTapeStatus function indicates whether the tape device is
1452 * ready to process tape commands.
1453 * Parameters: HANDLE hDevice handle of open device
1454 * Variables :
1455 * Result : API returncode
1456 * Remark :
1457 * Status : UNTESTED STUB
1458 *
1459 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1460 *****************************************************************************/
1461
1462DWORD WIN32API GetTapeStatus(HANDLE hDevice)
1463{
1464 dprintf(("KERNEL32: OS2GetTapeStatus(%08xh) not implemented - ERROR_NOT_SUPPORTED.\n",
1465 hDevice));
1466
1467 return (ERROR_NOT_SUPPORTED);
1468}
1469
1470
1471/*****************************************************************************
1472 * Name : BOOL GetThreadSelectorEntry
1473 * Purpose : The GetThreadSelectorEntry function retrieves a descriptor table
1474 * entry for the specified selector and thread.
1475 * Parameters: HANDLE hThread handle of thread that contains selector
1476 * DWORD dwSelector number of selector value to look up
1477 * LPLDT_ENTRY lpSelectorEntry address of selector entry structure
1478 * Variables :
1479 * Result : TRUE / FALSE
1480 * Remark :
1481 * Status : UNTESTED STUB
1482 *
1483 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1484 *****************************************************************************/
1485
1486BOOL WIN32API GetThreadSelectorEntry(HANDLE hThread,
1487 DWORD dwSelector,
1488 LPLDT_ENTRY lpSelectorEntry)
1489{
1490 dprintf(("KERNEL32: GetThreadSelectorEntry(%08xh,%08xh,%08xh) not implemented.\n",
1491 hThread,
1492 dwSelector,
1493 lpSelectorEntry));
1494
1495 return (FALSE);
1496}
1497
1498
1499/*****************************************************************************
1500 * Name : BOOL GetThreadTimes
1501 * Purpose : The GetThreadTimes function obtains timing information about a specified thread.
1502 * Parameters: HANDLE hThread specifies the thread of interest
1503 * LPFILETIME lpCreationTime when the thread was created
1504 * LPFILETIME lpExitTime when the thread exited
1505 * LPFILETIME lpKernelTime time the thread has spent in kernel mode
1506 * LPFILETIME lpUserTime time the thread has spent in user mode
1507 * Variables :
1508 * Result : TRUE / FALSE
1509 * Remark :
1510 * Status : UNTESTED STUB
1511 *
1512 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1513 *****************************************************************************/
1514
1515BOOL WIN32API GetThreadTimes(HANDLE hThread,
1516 LPFILETIME lpCreationTime,
1517 LPFILETIME lpExitTime,
1518 LPFILETIME lpKernelTime,
1519 LPFILETIME lpUserTime)
1520{
1521 dprintf(("Kernel32: GetThreadTimes(%08xh,%08xh,%08xh,%08xh,%08xh) not implemented.\n",
1522 hThread,
1523 lpCreationTime,
1524 lpExitTime,
1525 lpKernelTime,
1526 lpUserTime));
1527
1528 return (FALSE);
1529}
1530
1531
1532
1533/*****************************************************************************
1534 * Name : BOOL PostQueuedCompletionStatus
1535 * Purpose : The PostQueuedCompletionStatus function lets you post an I/O
1536 * completion packet to an I/O completion port. The I/O completion
1537 * packet will satisfy an outstanding call to the GetQueuedCompletionStatus
1538 * function. The GetQueuedCompletionStatus function returns with the three
1539 * values passed as the second, third, and fourth parameters of the call
1540 * to PostQueuedCompletionStatus.
1541 * Parameters: HANDLE CompletionPort handle to an I/O completion port
1542 * DWORD dwNumberOfBytesTransferred
1543 * DWORD dwCompletionKey
1544 * LPOVERLAPPED lpOverlapped
1545 * Variables :
1546 * Result : TRUE / FALSE
1547 * Remark :
1548 * Status : UNTESTED STUB
1549 *
1550 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1551 *****************************************************************************/
1552
1553BOOL WIN32API PostQueuedCompletionStatus(HANDLE CompletionPort,
1554 DWORD dwNumberOfBytesTransferred,
1555 DWORD dwCompletionKey,
1556 LPOVERLAPPED lpOverlapped)
1557{
1558 dprintf(("Kernel32: PostQueuedCompletionStatus(%08xh,%08xh,%08xh,%08xh) not implemented.",
1559 CompletionPort,
1560 dwNumberOfBytesTransferred,
1561 dwCompletionKey,
1562 lpOverlapped));
1563
1564 return (FALSE);
1565}
1566
1567
1568/*****************************************************************************
1569 * Name : DWORD PrepareTape
1570 * Purpose : The PrepareTape function prepares the tape to be accessed or removed.
1571 * Parameters: HANDLE hDevice handle of open device
1572 * DWORD dwOperation preparation method
1573 * BOOL bImmediate return after operation begins
1574 * Variables :
1575 * Result : API returncode
1576 * Remark :
1577 * Status : UNTESTED STUB
1578 *
1579 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1580 *****************************************************************************/
1581
1582DWORD WIN32API PrepareTape(HANDLE hDevice,
1583 DWORD dwOperation,
1584 BOOL bImmediate)
1585{
1586 dprintf(("Kernel32: PrepareTape(%08xh,%08xh,%08xh) not implemented - ERROR_NOT_SUPPORTED.\n",
1587 hDevice,
1588 dwOperation,
1589 bImmediate));
1590
1591 return (ERROR_NOT_SUPPORTED);
1592}
1593
1594
1595/*****************************************************************************
1596 * Name : DWORD QueryDosDeviceA
1597 * Purpose : The QueryDosDevice function lets an application obtain information
1598 * about MS-DOS device names. The function can obtain the current
1599 * mapping for a particular MS-DOS device name. The function can also
1600 * obtain a list of all existing MS-DOS device names.
1601 * MS-DOS device names are stored as symbolic links in the Windows NT
1602 * object name space. The code that converts an MS-DOS path into a
1603 * corresponding Windows NT path uses these symbolic links to map
1604 * MS-DOS devices and drive letters. The QueryDosDevice function
1605 * provides a mechanism whereby a Win32-based application can query
1606 * the names of the symbolic links used to implement the MS-DOS device
1607 * namespace as well as the value of each specific symbolic link.
1608 * Parameters: LPCTSTR lpDeviceName address of MS-DOS device name string
1609 * LPTSTR lpTargetPath ddress of buffer for storing query results
1610 * DWORD ucchMax maximum storage capacity of buffer
1611 * Variables :
1612 * Result : pointer to lpTargetPath
1613 * Remark :
1614 * Status : UNTESTED STUB
1615 *
1616 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1617 *****************************************************************************/
1618
1619DWORD WIN32API QueryDosDeviceA(LPCTSTR lpDeviceName,
1620 LPTSTR lpTargetPath,
1621 DWORD ucchMax)
1622{
1623 dprintf(("Kernel32: QueryDosDeviceA(%s,%08xh,%08xh) not implemented.\n",
1624 lpDeviceName,
1625 lpTargetPath,
1626 ucchMax));
1627
1628 return (0);
1629}
1630
1631
1632/*****************************************************************************
1633 * Name : DWORD QueryDosDeviceW
1634 * Purpose : The QueryDosDevice function lets an application obtain information
1635 * about MS-DOS device names. The function can obtain the current
1636 * mapping for a particular MS-DOS device name. The function can also
1637 * obtain a list of all existing MS-DOS device names.
1638 * MS-DOS device names are stored as symbolic links in the Windows NT
1639 * object name space. The code that converts an MS-DOS path into a
1640 * corresponding Windows NT path uses these symbolic links to map
1641 * MS-DOS devices and drive letters. The QueryDosDevice function
1642 * provides a mechanism whereby a Win32-based application can query
1643 * the names of the symbolic links used to implement the MS-DOS device
1644 * namespace as well as the value of each specific symbolic link.
1645 * Parameters: LPCTSTR lpDeviceName address of MS-DOS device name string
1646 * LPTSTR lpTargetPath ddress of buffer for storing query results
1647 * DWORD ucchMax maximum storage capacity of buffer
1648 * Variables :
1649 * Result : pointer to lpTargetPath
1650 * Remark :
1651 * Status : UNTESTED STUB
1652 *
1653 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1654 *****************************************************************************/
1655
1656DWORD WIN32API QueryDosDeviceW(LPCWSTR lpDeviceName,
1657 LPWSTR lpTargetPath,
1658 DWORD ucchMax)
1659{
1660 dprintf(("Kernel32: QueryDosDeviceW(%s,%08xh,%08xh) not implemented.\n",
1661 lpDeviceName,
1662 lpTargetPath,
1663 ucchMax));
1664
1665 return (0);
1666}
1667
1668
1669/*****************************************************************************
1670 * Name : DWORD ReadProcessMemory
1671 * Purpose : The ReadProcessMemory function reads memory in a specified process.
1672 * The entire area to be read must be accessible, or the operation fails.
1673 * Parameters: HANDLE hProcess handle of the process whose memory is read
1674 * LPCVOID lpBaseAddress address to start reading
1675 * LPVOID lpBuffer address of buffer to place read data
1676 * DWORD cbRead number of bytes to read
1677 * LPDWORD lpNumberOfBytesRead address of number of bytes read
1678 * Variables :
1679 * Result : TRUE / FALSE
1680 * Remark :
1681 * Status : UNTESTED STUB
1682 *
1683 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1684 *****************************************************************************/
1685
1686DWORD WIN32API ReadProcessMemory(HANDLE hProcess,
1687 LPCVOID lpBaseAddress,
1688 LPVOID lpBuffer,
1689 DWORD cbRead,
1690 LPDWORD lpNumberOfBytesRead)
1691{
1692 dprintf(("Kernel32: ReadProcessMemory(%08xh,%08xh,%08xh,%08xh,%08xh) not completely implemented",
1693 hProcess,
1694 lpBaseAddress,
1695 lpBuffer,
1696 cbRead,
1697 lpNumberOfBytesRead));
1698
1699 // do some (faked) access check
1700 if(hProcess != GetCurrentProcess())
1701 {
1702 dprintf(("WARNING: ReadProcessMemory: can't read memory from other processes!"));
1703 SetLastError(ERROR_ACCESS_DENIED);
1704 return FALSE;
1705 }
1706
1707 if(IsBadReadPtr(lpBaseAddress, cbRead)) {
1708 dprintf(("ERROR: ReadProcessMemory bad source pointer!"));
1709 if(lpNumberOfBytesRead)
1710 *lpNumberOfBytesRead = 0;
1711 SetLastError(ERROR_ACCESS_DENIED);
1712 return FALSE;
1713 }
1714 // FIXME: check this, if we ever run win32 binaries in different addressspaces
1715 // ... and add a sizecheck
1716 memcpy(lpBuffer,lpBaseAddress,cbRead);
1717 if(lpNumberOfBytesRead)
1718 *lpNumberOfBytesRead = cbRead;
1719
1720 SetLastError(ERROR_SUCCESS);
1721 return TRUE;
1722}
1723
1724/*****************************************************************************
1725 * Name : DWORD WriteProcessMemory
1726 * Purpose : The WriteProcessMemory function writes memory in a specified
1727 * process. The entire area to be written to must be accessible,
1728 * or the operation fails.
1729 * Parameters: HANDLE hProcess handle of process whose memory is written to
1730 * LPVOID lpBaseAddress address to start writing to
1731 * LPVOID lpBuffer address of buffer to write data to
1732 * DWORD cbWrite number of bytes to write
1733 * LPDWORD lpNumberOfBytesWritten actual number of bytes written
1734 * Variables :
1735 * Result : TRUE / FALSE
1736 * Remark :
1737 * Status : UNTESTED STUB
1738 *
1739 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1740 *****************************************************************************/
1741
1742BOOL WIN32API WriteProcessMemory(HANDLE hProcess,
1743 LPCVOID lpBaseAddress,
1744 LPVOID lpBuffer,
1745 DWORD cbWrite,
1746 LPDWORD lpNumberOfBytesWritten)
1747{
1748 // do some (faked) access check
1749 if(hProcess != GetCurrentProcess())
1750 {
1751 dprintf(("Kernel32: WriteProcessMemory(%08xh,%08xh,%08xh,%08xh,%08xh) not implemented (different process!!)",
1752 hProcess, lpBaseAddress, lpBuffer, cbWrite, lpNumberOfBytesWritten));
1753 SetLastError(ERROR_ACCESS_DENIED);
1754 return FALSE;
1755 }
1756 dprintf(("Kernel32: WriteProcessMemory(%08xh,%08xh,%08xh,%08xh,%08xh))",
1757 hProcess,lpBaseAddress, lpBuffer, cbWrite, lpNumberOfBytesWritten));
1758
1759 if(IsBadWritePtr((LPVOID)lpBaseAddress, cbWrite))
1760 {
1761 dprintf(("ERROR: WriteProcessMemory bad destination pointer!"));
1762 if(lpNumberOfBytesWritten)
1763 *lpNumberOfBytesWritten = 0;
1764 SetLastError(ERROR_ACCESS_DENIED);
1765 return FALSE;
1766 }
1767
1768 // FIXME: check this, if we ever run win32 binaries in different addressspaces
1769 // ... and add a sizecheck
1770 memcpy((void*)lpBaseAddress,lpBuffer,cbWrite);
1771 if(lpNumberOfBytesWritten)
1772 *lpNumberOfBytesWritten = cbWrite;
1773
1774 SetLastError(ERROR_SUCCESS);
1775 return TRUE;
1776}
1777
1778
1779/*****************************************************************************
1780 * Name : BOOL SetComputerNameA
1781 * Purpose : The SetComputerNameA function sets the computer name to be used
1782 * the next time the system is restarted.
1783 * Parameters: LPCTSTR lpszName address of new computer name
1784 * Variables :
1785 * Result : TRUE / FALSE
1786 * Remark :
1787 * Status : UNTESTED STUB
1788 *
1789 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1790 *****************************************************************************/
1791
1792BOOL WIN32API SetComputerNameA(LPCTSTR lpszName)
1793{
1794 dprintf(("Kernel32: SetComputerNameA(%s) not implemented.\n",
1795 lpszName));
1796
1797 return (FALSE);
1798}
1799
1800
1801/*****************************************************************************
1802 * Name : BOOL SetComputerNameW
1803 * Purpose : The SetComputerNameW function sets the computer name to be used
1804 * the next time the system is restarted.
1805 * Parameters: LPCTSTR lpszName address of new computer name
1806 * Variables :
1807 * Result : TRUE / FALSE
1808 * Remark :
1809 * Status : UNTESTED STUB
1810 *
1811 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1812 *****************************************************************************/
1813
1814BOOL WIN32API SetComputerNameW(LPCWSTR lpszName)
1815{
1816 dprintf(("Kernel32: SetComputerNameW(%s) not implemented.\n",
1817 lpszName));
1818
1819 return (FALSE);
1820}
1821
1822
1823/*****************************************************************************
1824 * Name : VOID SetFileApisToOEM
1825 * Purpose : The SetFileApisToOEM function causes a set of Win32 file functions
1826 * to use the OEM character set code page. This function is useful
1827 * for 8-bit console input and output operations.
1828 * Parameters: VOID
1829 * Variables :
1830 * Result :
1831 * Remark :
1832 * Status : UNTESTED STUB
1833 *
1834 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1835 *****************************************************************************/
1836
1837VOID WIN32API SetFileApisToOEM(VOID)
1838{
1839 dprintf(("Kernel32: SetFileApisToOEM() not implemented.\n"));
1840}
1841
1842
1843/*****************************************************************************
1844 * Name : BOOL SetHandleInformation
1845 * Purpose : The SetHandleInformation function sets certain properties of an
1846 * object handle. The information is specified as a set of bit flags.
1847 * Parameters: HANDLE hObject handle to an object
1848 * DWORD dwMask specifies flags to change
1849 * DWORD dwFlags specifies new values for flags
1850 * Variables :
1851 * Result : TRUE / FALSE
1852 * Remark :
1853 * Status : UNTESTED STUB
1854 *
1855 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1856 *****************************************************************************/
1857
1858BOOL WIN32API SetHandleInformation(HANDLE hObject,
1859 DWORD dwMask,
1860 DWORD dwFlags)
1861{
1862 dprintf(("KERNEL32: SetHandleInformation(%08xh,%08xh,%08xh) not implemented.\n",
1863 hObject,
1864 dwMask,
1865 dwFlags));
1866
1867 return (FALSE);
1868}
1869
1870
1871/*****************************************************************************
1872 * Name : BOOL SetMailslotInfo
1873 * Purpose : The SetMailslotInfo function sets the time-out value used by the
1874 * specified mailslot for a read operation.
1875 * Parameters: HANDLE hObject handle to a mailslot object
1876 * DWORD dwReadTimeout read time-out
1877 * Variables :
1878 * Result : TRUE / FALSE
1879 * Remark :
1880 * Status : UNTESTED STUB
1881 *
1882 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1883 *****************************************************************************/
1884
1885BOOL WIN32API SetMailslotInfo(HANDLE hObject,
1886 DWORD dwReadTimeout)
1887{
1888 dprintf(("KERNEL32: SetMailslotInfo(%08xh,%08xh) not implemented.\n",
1889 hObject,
1890 dwReadTimeout));
1891
1892 return (FALSE);
1893}
1894
1895
1896/*****************************************************************************
1897 * Name : BOOL SetSystemPowerState
1898 * Purpose : The SetSystemPowerState function suspends the system by shutting
1899 * power down. Depending on the ForceFlag parameter, the function
1900 * either suspends operation immediately or requests permission from
1901 * all applications and device drivers before doing so.
1902 * Parameters: BOOL fSuspend
1903 * BOOL fForce
1904 * Variables :
1905 * Result : TRUE / FALSE
1906 * Remark :
1907 * Status : UNTESTED STUB
1908 *
1909 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1910 *****************************************************************************/
1911
1912BOOL WIN32API SetSystemPowerState(BOOL fSuspend,
1913 BOOL fForce)
1914{
1915 dprintf(("KERNEL32: SetSystemPowerState(%08xh,%08xh) not implemented.\n",
1916 fSuspend,
1917 fForce));
1918
1919 return (FALSE);
1920}
1921
1922
1923/*****************************************************************************
1924 * Name : BOOL SetSystemTimeAdjustment
1925 * Purpose : The SetSystemTimeAdjustment function tells the system to enable
1926 * or disable periodic time adjustments to its time of day clock.
1927 * Such time adjustments are used to synchronize the time of day
1928 * with some other source of time information. When periodic time
1929 * adjustments are enabled, they are applied at each clock interrupt.
1930 * Parameters: DWORD dwTimeAdjustment
1931 * BOOL bTimeAdjustmentDisabled
1932 * Variables :
1933 * Result : TRUE / FALSE
1934 * Remark :
1935 * Status : UNTESTED STUB
1936 *
1937 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1938 *****************************************************************************/
1939
1940BOOL WIN32API SetSystemTimeAdjustment(DWORD dwTimeAdjustment,
1941 BOOL bTimeAdjustmentDisabled)
1942{
1943 dprintf(("KERNEL32: SetSystemTimeAdjustment(%08xh,%08xh) not implemented.\n",
1944 dwTimeAdjustment,
1945 bTimeAdjustmentDisabled));
1946
1947 return (FALSE);
1948}
1949
1950
1951/*****************************************************************************
1952 * Name : DWORD SetTapeParameters
1953 * Purpose : The SetTapeParameters function either specifies the block size
1954 * of a tape or configures the tape device.
1955 * Parameters: HANDLE hDevice handle of open device
1956 * DWORD dwOperation type of information to set
1957 * LPVOID lpTapeInformation address of buffer with information to set
1958 * Variables :
1959 * Result : API returncode
1960 * Remark :
1961 * Status : UNTESTED STUB
1962 *
1963 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1964 *****************************************************************************/
1965
1966BOOL WIN32API SetTapeParameters(HANDLE hDevice,
1967 DWORD dwOperation,
1968 LPVOID lpTapeInformation)
1969{
1970 dprintf(("KERNEL32: SetTapeParameters(%08xh,%08xh,%08xh) not implemented - ERROR_NOT_SUPPORTED.\n",
1971 hDevice,
1972 dwOperation,
1973 lpTapeInformation));
1974
1975 return (ERROR_NOT_SUPPORTED);
1976}
1977
1978
1979/*****************************************************************************
1980 * Name : DWORD SetTapePosition
1981 * Purpose : The SetTapePosition sets the tape position on the specified device.
1982 * Parameters: HANDLE hDevice handle of open device
1983 * DWORD dwPositionMethod type of positioning to perform
1984 * DWORD dwPartition new tape partition
1985 * DWORD dwOffsetLow low-order 32 bits of tape position
1986 * DWORD dwOffsetHigh high-order 32 bits of tape position
1987 * BOOL bImmediate return after operation begins
1988 * Variables :
1989 * Result : API returncode
1990 * Remark :
1991 * Status : UNTESTED STUB
1992 *
1993 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
1994 *****************************************************************************/
1995
1996BOOL WIN32API SetTapePosition(HANDLE hDevice,
1997 DWORD dwPositionMethod,
1998 DWORD dwPartition,
1999 DWORD dwOffsetLow,
2000 DWORD dwOffsetHigh,
2001 BOOL bImmediate)
2002{
2003 dprintf(("KERNEL32: SetTapePosition(%08xh,%08xh,%08xh,%08xh,%08xh,%08xh) not implemented - ERROR_NOT_SUPPORTED.\n",
2004 hDevice,
2005 dwPositionMethod,
2006 dwPartition,
2007 dwOffsetLow,
2008 dwOffsetHigh,
2009 bImmediate));
2010
2011 return (ERROR_NOT_SUPPORTED);
2012}
2013
2014
2015/*****************************************************************************
2016 * Name : DWORD SetThreadAffinityMask
2017 * Purpose : The SetThreadAffinityMask function sets a processor affinity
2018 * mask for a specified thread.
2019 * A thread affinity mask is a bit vector in which each bit
2020 * represents the processors that a thread is allowed to run on.
2021 * A thread affinity mask must be a proper subset of the process
2022 * affinity mask for the containing process of a thread. A thread
2023 * is only allowed to run on the processors its process is allowed to run on.
2024 * Parameters: HANDLE hThread handle to the thread of interest
2025 * DWORD dwThreadAffinityMask a thread affinity mask
2026 * Variables :
2027 * Result : TRUE / FALSE
2028 * Remark :
2029 * Status : UNTESTED STUB
2030 *
2031 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
2032 *****************************************************************************/
2033
2034DWORD WIN32API SetThreadAffinityMask(HANDLE hThread,
2035 DWORD dwThreadAffinityMask)
2036{
2037 dprintf(("KERNEL32: SetThreadAffinityMask(%08xh,%08xh) not implemented.\n",
2038 hThread,
2039 dwThreadAffinityMask));
2040
2041 return (0);
2042}
2043
2044
2045
2046/*****************************************************************************
2047 * Name : BOOL UpdateResourceA
2048 * Purpose : The UpdateResourceA function adds, deletes, or replaces a resource
2049 * in an executable file.
2050 * Parameters: HANDLE hUpdateFile update-file handle
2051 * LPCTSTR lpszType address of resource type to update
2052 * LPCTSTR lpszName address of resource name to update
2053 * WORD IDLanguage language identifier of resource
2054 * LPVOID lpvData address of resource data
2055 * DWORD cbData length of resource data, in bytes
2056 * Variables :
2057 * Result : TRUE / FALSE
2058 * Remark :
2059 * Status : UNTESTED STUB
2060 *
2061 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
2062 *****************************************************************************/
2063
2064BOOL WIN32API UpdateResourceA(HANDLE hUpdateFile,
2065 LPCTSTR lpszType,
2066 LPCTSTR lpszName,
2067 WORD IDLanguage,
2068 LPVOID lpvData,
2069 DWORD cbData)
2070{
2071 dprintf(("KERNEL32: UpdateResourceA(%08xh,%s,%s,%08xh,%08xh,%08xh) not implemented.\n",
2072 hUpdateFile,
2073 lpszType,
2074 lpszName,
2075 IDLanguage,
2076 lpvData,
2077 cbData));
2078
2079 return (FALSE);
2080}
2081
2082
2083/*****************************************************************************
2084 * Name : BOOL UpdateResourceW
2085 * Purpose : The UpdateResourceW function adds, deletes, or replaces a resource
2086 * in an executable file.
2087 * Parameters: HANDLE hUpdateFile update-file handle
2088 * LPCTSTR lpszType address of resource type to update
2089 * LPCTSTR lpszName address of resource name to update
2090 * WORD IDLanguage language identifier of resource
2091 * LPVOID lpvData address of resource data
2092 * DWORD cbData length of resource data, in bytes
2093 * Variables :
2094 * Result : TRUE / FALSE
2095 * Remark :
2096 * Status : UNTESTED STUB
2097 *
2098 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
2099 *****************************************************************************/
2100
2101BOOL WIN32API UpdateResourceW(HANDLE hUpdateFile,
2102 LPCWSTR lpszType,
2103 LPCWSTR lpszName,
2104 WORD IDLanguage,
2105 LPVOID lpvData,
2106 DWORD cbData)
2107{
2108 dprintf(("KERNEL32: UpdateResourceW(%08xh,%s,%s,%08xh,%08xh,%08xh) not implemented.\n",
2109 hUpdateFile,
2110 lpszType,
2111 lpszName,
2112 IDLanguage,
2113 lpvData,
2114 cbData));
2115
2116 return (FALSE);
2117}
2118
2119/*****************************************************************************
2120 * Name : BOOL WriteTapemark
2121 * Purpose : The WriteTapemark function writes a specified number of filemarks,
2122 * setmarks, short filemarks, or long filemarks to a tape device.
2123 * These tapemarks divide a tape partition into smaller areas.
2124 * Parameters: HANDLE hDevice handle of open device
2125 * DWORD dwTapemarkType type of tapemarks to write
2126 * DWORD dwTapemarkCount number of tapemarks to write
2127 * BOOL bImmediate return after write begins
2128 * Variables :
2129 * Result : API returncode
2130 * Remark :
2131 * Status : UNTESTED STUB
2132 *
2133 * Author : Patrick Haller [Mon, 1998/06/15 08:00]
2134 *****************************************************************************/
2135
2136DWORD WIN32API WriteTapemark(HANDLE hDevice,
2137 DWORD dwTapemarkType,
2138 DWORD dwTapemarkCount,
2139 BOOL bImmediate)
2140{
2141 dprintf(("KERNEL32: WriteTapemark(%08xh,%08xh,%08xh,%08xh) not implemented - ERROR_NOT_SUPPORTED.\n",
2142 hDevice,
2143 dwTapemarkType,
2144 dwTapemarkCount,
2145 bImmediate));
2146
2147 return (ERROR_NOT_SUPPORTED);
2148}
2149
2150
2151/*****************************************************************************
2152 * Name : DWORD CmdBatNotification
2153 * Purpose : Unknown, used by /winnt/cmd.exe
2154 * Parameters: Unknown (wrong)
2155 * Variables :
2156 * Result : Unknown
2157 * Remark :
2158 * Status : UNTESTED STUB
2159 *
2160 * Author : Patrick Haller [Tue, 1999/06/08 21:44]
2161 *****************************************************************************/
2162
2163DWORD WIN32API CmdBatNotification(DWORD x1)
2164{
2165 dprintf(("KERNEL32: CmdBatNotification(%08xh) not implemented\n",
2166 x1));
2167
2168 return (0);
2169}
2170
2171
2172/*****************************************************************************
2173 * Name : DWORD GetVDMCurrentDirectories
2174 * Purpose : Unknown, used by /winnt/cmd.exe
2175 * Parameters: Unknown (wrong)
2176 * Variables :
2177 * Result : Unknown
2178 * Remark :
2179 * Status : UNTESTED STUB
2180 *
2181 * Author : Patrick Haller [Tue, 1999/06/08 21:44]
2182 *****************************************************************************/
2183
2184DWORD WIN32API GetVDMCurrentDirectories(DWORD x1)
2185{
2186 dprintf(("KERNEL32: GetVDMCurrentDirectories(%08xh) not implemented\n",
2187 x1));
2188
2189 return (0);
2190}
2191
2192
2193/*****************************************************************************
2194 * Name : DWORD SetThreadPriorityBoost
2195 * Purpose : Unknown
2196 * Parameters: Unknown (wrong)
2197 * Variables :
2198 * Result : Unknown
2199 * Remark :
2200 * Status : UNTESTED STUB
2201 *
2202 * Author : Patrick Haller [Tue, 1999/06/08 21:44]
2203 *****************************************************************************/
2204
2205DWORD WIN32API SetThreadPriorityBoost(DWORD x1,
2206 DWORD x2)
2207{
2208 dprintf(("KERNEL32: SetThreadPriorityBoost(%08xh, %08xh) not implemented\n",
2209 x1,
2210 x2));
2211
2212 return (0);
2213}
Note: See TracBrowser for help on using the repository browser.