windows-pr 0.8.7 → 0.9.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (53) hide show
  1. data/CHANGES +15 -0
  2. data/MANIFEST +9 -1
  3. data/lib/windows/clipboard.rb +1 -2
  4. data/lib/windows/com/automation.rb +58 -0
  5. data/lib/windows/com.rb +0 -1
  6. data/lib/windows/console.rb +0 -1
  7. data/lib/windows/debug.rb +0 -1
  8. data/lib/windows/device_io.rb +0 -1
  9. data/lib/windows/error.rb +37 -32
  10. data/lib/windows/eventlog.rb +5 -6
  11. data/lib/windows/file.rb +10 -36
  12. data/lib/windows/file_mapping.rb +0 -1
  13. data/lib/windows/filesystem.rb +0 -1
  14. data/lib/windows/gdi/bitmap.rb +0 -1
  15. data/lib/windows/gdi/device_context.rb +0 -1
  16. data/lib/windows/gdi/painting_drawing.rb +0 -1
  17. data/lib/windows/handle.rb +0 -1
  18. data/lib/windows/library.rb +0 -1
  19. data/lib/windows/memory.rb +0 -1
  20. data/lib/windows/msvcrt/buffer.rb +0 -1
  21. data/lib/windows/msvcrt/directory.rb +8 -9
  22. data/lib/windows/msvcrt/file.rb +0 -1
  23. data/lib/windows/msvcrt/io.rb +0 -1
  24. data/lib/windows/msvcrt/string.rb +0 -1
  25. data/lib/windows/msvcrt/time.rb +0 -1
  26. data/lib/windows/national.rb +0 -1
  27. data/lib/windows/network/management.rb +523 -0
  28. data/lib/windows/network/snmp.rb +90 -0
  29. data/lib/windows/network/winsock.rb +126 -0
  30. data/lib/windows/nio.rb +0 -1
  31. data/lib/windows/ntfs/file.rb +58 -0
  32. data/lib/windows/path.rb +105 -38
  33. data/lib/windows/pipe.rb +0 -1
  34. data/lib/windows/security.rb +292 -6
  35. data/lib/windows/service.rb +0 -1
  36. data/lib/windows/shell.rb +4 -1
  37. data/lib/windows/sound.rb +0 -1
  38. data/lib/windows/synchronize.rb +0 -1
  39. data/lib/windows/system_info.rb +0 -1
  40. data/lib/windows/thread.rb +0 -1
  41. data/lib/windows/time.rb +0 -1
  42. data/lib/windows/unicode.rb +0 -1
  43. data/lib/windows/volume.rb +0 -1
  44. data/lib/windows/window/dialog.rb +89 -0
  45. data/lib/windows/window/message.rb +289 -0
  46. data/lib/windows/window/properties.rb +18 -0
  47. data/lib/windows/window/timer.rb +17 -0
  48. data/lib/windows/window.rb +0 -1
  49. data/test/tc_com.rb +17 -19
  50. data/test/tc_msvcrt_directory.rb +57 -27
  51. data/test/tc_msvcrt_string.rb +74 -18
  52. data/windows-pr.gemspec +4 -5
  53. metadata +33 -15
data/CHANGES CHANGED
@@ -1,3 +1,18 @@
1
+ = 0.9.0 - 26-Jul-2008
2
+ * The process of converting prototypes from 'P' to 'S' has begun. This
3
+ means that this library now requires win32-api 1.2.0 or later.
4
+ * Added the Windows::Window::Message module.
5
+ * Added the Windows::Window::Timer module.
6
+ * Added the Windows::Window::Dialog module.
7
+ * Added many more functions and constants to the Windows::Security module.
8
+ * All ACE related constants have been move from the Windows::File module and
9
+ are instead defined in the Windows::Security module. Not to worry, though.
10
+ The Windows::File module now mixes in the Windows::Security module.
11
+ * Added several profile related functions to the Windows::Shell module.
12
+ * Changed the prototype of ConvertSidToStringSid and ConvertStringSidToSid
13
+ back to 'LP' in the Windows::Security module. I'm not sure why I changed
14
+ those before. If this causes too much grief I'll change them back.
15
+
1
16
  = 0.8.7 - 23-Jun-2008
2
17
  * Wide character fix for the get_last_error helper function. Thanks go to
3
18
  Dave Whitley for the spot.
data/MANIFEST CHANGED
@@ -51,4 +51,12 @@ lib/windows/msvcrt/string.rb
51
51
  lib/windows/msvcrt/time.rb
52
52
 
53
53
  lib/windows/network/management.rb
54
- lib/windows/network/snmp.rb
54
+ lib/windows/network/snmp.rb
55
+ lib/windows/network/winsock.rb
56
+
57
+ lib/windows/ntfs/file.rb
58
+
59
+ lib/windows/window/dialog.rb
60
+ lib/windows/window/message.rb
61
+ lib/windows/window/properties.rb
62
+ lib/windows/window/timer.rb
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module Clipboard
@@ -32,6 +31,6 @@ module Windows
32
31
  API.new('IsClipboardFormatAvailable', 'I', 'B', 'user32')
33
32
  API.new('GetClipboardFormatName', 'IPI', 'I', 'user32')
34
33
  API.new('EnumClipboardFormats', 'I', 'I', 'user32')
35
- API.new('RegisterClipboardFormat', 'P', 'I', 'user32')
34
+ API.new('RegisterClipboardFormat', 'S', 'I', 'user32')
36
35
  end
37
36
  end
@@ -0,0 +1,58 @@
1
+ require 'windows/api'
2
+
3
+ module Windows
4
+ module COM
5
+ module Automation
6
+ API.auto_namespace = 'Windows::COM::Automation'
7
+ API.auto_constant = true
8
+ API.auto_method = true
9
+ API.auto_unicode = false
10
+
11
+ API.new('BstrFromVector', 'PP', 'L', 'oleaut32')
12
+ API.new('CreateErrorInfo', 'P', 'L', 'oleaut32')
13
+ API.new('CreateTypeLib2', 'PPP', 'L', 'oleaut32')
14
+ API.new('DispGetIDsOfNames', 'PPLP', 'L', 'oleaut32')
15
+ API.new('DispGetParam', 'PLLPP', 'L', 'oleaut32')
16
+ API.new('DispInvoke', 'PPPLPPPP', 'L', 'oleaut32')
17
+ API.new('GetActiveObject', 'PPP', 'L', 'oleaut32')
18
+ API.new('LoadRegTypeLib', 'PLLLP', 'L', 'oleaut32')
19
+ API.new('LoadTypeLib', 'PPP', 'L', 'oleaut32')
20
+ API.new('LoadTypeLibEx', 'PPP', 'L', 'oleaut32')
21
+ API.new('RegisterActiveObject', 'PPLP', 'L', 'oleaut32')
22
+ API.new('RevokeActiveObject', 'LP', 'L', 'oleaut32')
23
+ API.new('RegisterTypeLib', 'PPP', 'L', 'oleaut32')
24
+ API.new('SafeArrayAccessData', 'PP', 'L', 'oleaut32')
25
+ API.new('SafeArrayAllocData', 'P', 'L', 'oleaut32')
26
+ API.new('SafeArrayAllocDescriptor', 'LP', 'L', 'oleaut32')
27
+ API.new('SafeArrayCopy', 'PP', 'L', 'oleaut32')
28
+ API.new('SafeArrayCopyData', 'PP', 'L', 'oleaut32')
29
+ API.new('SafeArrayCreate', 'LLP', 'P', 'oleaut32')
30
+ API.new('SafeArrayCreateVector', 'LLL', 'P', 'oleaut32')
31
+ API.new('SafeArrayDestroy', 'P', 'L', 'oleaut32')
32
+ API.new('SafeArrayDestroyData', 'P', 'L', 'oleaut32')
33
+ API.new('SafeArrayDestroyDescriptor', 'P', 'L', 'oleaut32')
34
+ API.new('SafeArrayGetDim', 'P', 'L', 'oleaut32')
35
+ API.new('SafeArrayGetElement', 'PLP', 'L', 'oleaut32')
36
+ API.new('SafeArrayGetElemsize', 'P', 'L', 'oleaut32')
37
+ API.new('SafeArrayGetLBound', 'PLP', 'L', 'oleaut32')
38
+ API.new('SafeArrayGetUBound', 'PLP', 'L', 'oleaut32')
39
+ API.new('SafeArrayLock', 'P', 'L', 'oleaut32')
40
+ API.new('SafeArrayPtrOfIndex', 'PPP', 'L', 'oleaut32')
41
+ API.new('SafeArrayPutElement', 'PPP', 'L', 'oleaut32')
42
+ API.new('SafeArrayRedim', 'PP', 'L', 'oleaut32')
43
+ API.new('SafeArrayUnaccessData', 'P', 'L', 'oleaut32')
44
+ API.new('SafeArrayUnlock', 'P', 'L', 'oleaut32')
45
+ API.new('SetErrorInfo', 'LP', 'L', 'oleaut32')
46
+ API.new('SysAllocString', 'P', 'P', 'oleaut32')
47
+ API.new('SysAllocStringByteLen', 'PI', 'P', 'oleaut32')
48
+ API.new('SysFreeString', 'P', 'L', 'oleaut32')
49
+ API.new('SysReAllocString', 'PP', 'L', 'oleaut32')
50
+ API.new('SysReAllocStringLen', 'PPI', 'P', 'oleaut32')
51
+ API.new('SysStringByteLen', 'P', 'L', 'oleaut32')
52
+ API.new('SysStringLen', 'P', 'L', 'oleaut32')
53
+ API.new('SystemTimeToVariantTime', 'PP', 'I', 'oleaut32')
54
+ API.new('UnRegisterTypeLib', 'PLLLL', 'I', 'oleaut32')
55
+ API.new('VectorFromBstr', 'PP', 'L', 'oleaut32')
56
+ end
57
+ end
58
+ end
data/lib/windows/com.rb CHANGED
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module COM
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module Console
data/lib/windows/debug.rb CHANGED
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module Debug
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module DeviceIO
data/lib/windows/error.rb CHANGED
@@ -10,7 +10,6 @@
10
10
  # by the GetLastError() function.
11
11
  ############################################################################
12
12
  require 'windows/api'
13
- include Windows
14
13
 
15
14
  module Windows
16
15
  module Error
@@ -241,6 +240,12 @@ module Windows
241
240
  ERROR_I24_NO_MONITOR_SUPPORT = 0x12
242
241
  ERROR_I24_INVALID_PARAMETER = 0x13
243
242
 
243
+ APPLICATION_ERROR_MASK = 0x20000000
244
+ ERROR_SEVERITY_SUCCESS = 0x00000000
245
+ ERROR_SEVERITY_INFORMATIONAL = 0x40000000
246
+ ERROR_SEVERITY_WARNING = 0x80000000
247
+ ERROR_SEVERITY_ERROR = 0xc0000000
248
+
244
249
  ALLOWED_FAIL = 0x0001
245
250
  ALLOWED_ABORT = 0x0002
246
251
  ALLOWED_RETRY = 0x0004
@@ -286,45 +291,45 @@ module Windows
286
291
  TC_SIGNAL = 3
287
292
 
288
293
  # From WinError.h
289
- ERROR_INVALID_FLAGS = 4100 # 1004L
290
- ERROR_NO_UNICODE_TRANSLATION = 4371
294
+ ERROR_INVALID_FLAGS = 0x1004
295
+ ERROR_NO_UNICODE_TRANSLATION = 0x1113
291
296
 
292
- E_INVALIDARG = 2147942487 # 0x80070057L
293
- E_NOINTERFACE = 2147500034 # 0x80004002L
294
- E_NOTIMPL = 2147500033 # 0x80004001L
295
- E_OUTOFMEMORY = 2147942414 # 0x8007000EL
296
- E_UNEXPECTED = 2147549183 # 0x8000FFFFL
297
+ E_INVALIDARG = 0x80070057
298
+ E_NOINTERFACE = 0x80004002
299
+ E_NOTIMPL = 0x80004001
300
+ E_OUTOFMEMORY = 0x8007000E
301
+ E_UNEXPECTED = 0x8000FFFF
297
302
 
298
- RPC_E_TIMEOUT = 2147549471 # 0x8001011FL
303
+ RPC_E_TIMEOUT = 0x8001011F
299
304
 
300
- CO_E_NOT_SUPPORTED = 2147500065 # 0x80004021L
305
+ CO_E_NOT_SUPPORTED = 0x80004021
301
306
 
302
- CLASS_E_NOAGGREGATION = 2147746064 # 0x80040110L
307
+ CLASS_E_NOAGGREGATION = 0x80040110
303
308
 
304
309
  # Registry errors
305
- REGDB_E_CLASSNOTREG = 2147746132 # 0x80040154L
310
+ REGDB_E_CLASSNOTREG = 0x80040154
306
311
 
307
312
  # msterr.h
308
- SCHED_S_TASK_READY = 267008 # 0x00041300L
309
- SCHED_S_TASK_RUNNING = 267009 # 0x00041301L
310
- SCHED_S_TASK_DISABLED = 267010 # 0x00041302L
311
- SCHED_S_TASK_HAS_NOT_RUN = 267011 # 0x00041303L
312
- SCHED_S_TASK_HAS_NO_MORE_RUNS = 267012 # 0x00041304L
313
- SCHED_S_TASK_NOT_SCHEDULED = 267013 # 0x00041305L
314
- SCHED_S_TASK_TERMINATED = 267014 # 0x00041306L
315
- SCHED_S_TASK_NO_VALID_TRIGGERS = 267015 # 0x00041307L
316
- SCHED_S_EVENT_TRIGGER = 267016 # 0x00041308L
317
- SCHED_E_TRIGGER_NOT_FOUND = 267017 # 0x00041309L
318
- SCHED_E_TASK_NOT_READY = 267018 # 0x0004130AL
319
- SCHED_E_TASK_NOT_RUNNING = 267019 # 0x0004130BL
320
- SCHED_E_SERVICE_NOT_INSTALLED = 267020 # 0x0004130CL
321
- SCHED_E_CANNOT_OPEN_TASK = 267021 # 0x0004130DL
322
- SCHED_E_INVALID_TASK = 267022 # 0x0004130EL
323
- SCHED_E_ACCOUNT_INFORMATION_NOT_SET = 267023 # 0x0004130FL
324
- SCHED_E_ACCOUNT_NAME_NOT_FOUND = 267024 # 0x00041310L
325
- SCHED_E_ACCOUNT_DBASE_CORRUPT = 267025 # 0x00041311L
326
- SCHED_E_NO_SECURITY_SERVICES = 267026 # 0x00041312L
327
- SCHED_E_UNKNOWN_OBJECT_VERSION = 267027 # 0x00041313L
313
+ SCHED_S_TASK_READY = 0x00041300
314
+ SCHED_S_TASK_RUNNING = 0x00041301
315
+ SCHED_S_TASK_DISABLED = 0x00041302
316
+ SCHED_S_TASK_HAS_NOT_RUN = 0x00041303
317
+ SCHED_S_TASK_HAS_NO_MORE_RUNS = 0x00041304
318
+ SCHED_S_TASK_NOT_SCHEDULED = 0x00041305
319
+ SCHED_S_TASK_TERMINATED = 0x00041306
320
+ SCHED_S_TASK_NO_VALID_TRIGGERS = 0x00041307
321
+ SCHED_S_EVENT_TRIGGER = 0x00041308
322
+ SCHED_E_TRIGGER_NOT_FOUND = 0x00041309
323
+ SCHED_E_TASK_NOT_READY = 0x0004130A
324
+ SCHED_E_TASK_NOT_RUNNING = 0x0004130B
325
+ SCHED_E_SERVICE_NOT_INSTALLED = 0x0004130C
326
+ SCHED_E_CANNOT_OPEN_TASK = 0x0004130D
327
+ SCHED_E_INVALID_TASK = 0x0004130E
328
+ SCHED_E_ACCOUNT_INFORMATION_NOT_SET = 0x0004130F
329
+ SCHED_E_ACCOUNT_NAME_NOT_FOUND = 0x00041310
330
+ SCHED_E_ACCOUNT_DBASE_CORRUPT = 0x00041311
331
+ SCHED_E_NO_SECURITY_SERVICES = 0x00041312
332
+ SCHED_E_UNKNOWN_OBJECT_VERSION = 0x00041313
328
333
 
329
334
  # Socket errors
330
335
  WSA_INVALID_HANDLE = 6
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module EventLog
@@ -22,18 +21,18 @@ module Windows
22
21
 
23
22
  EVENTLOG_FULL_INFO = 0
24
23
 
25
- API.new('BackupEventLog', 'LP', 'B', 'advapi32')
26
- API.new('ClearEventLog', 'LP', 'B', 'advapi32')
24
+ API.new('BackupEventLog', 'LS', 'B', 'advapi32')
25
+ API.new('ClearEventLog', 'LS', 'B', 'advapi32')
27
26
  API.new('CloseEventLog', 'L', 'B', 'advapi32')
28
27
  API.new('DeregisterEventSource', 'L', 'B', 'advapi32')
29
28
  API.new('GetEventLogInformation', 'LLPLP', 'B', 'advapi32')
30
29
  API.new('GetNumberOfEventLogRecords', 'LP', 'B', 'advapi32')
31
30
  API.new('GetOldestEventLogRecord', 'LP', 'B', 'advapi32')
32
31
  API.new('NotifyChangeEventLog', 'LL', 'B', 'advapi32')
33
- API.new('OpenBackupEventLog', 'PP', 'L', 'advapi32')
34
- API.new('OpenEventLog', 'PP', 'L', 'advapi32')
32
+ API.new('OpenBackupEventLog', 'SS', 'L', 'advapi32')
33
+ API.new('OpenEventLog', 'SS', 'L', 'advapi32')
35
34
  API.new('ReadEventLog', 'LLLPLPP', 'B', 'advapi32')
36
- API.new('RegisterEventSource', 'PP', 'L', 'advapi32')
35
+ API.new('RegisterEventSource', 'SS', 'L', 'advapi32')
37
36
  API.new('ReportEvent', 'LIILPILPP', 'B', 'advapi32')
38
37
  end
39
38
  end
data/lib/windows/file.rb CHANGED
@@ -1,9 +1,10 @@
1
1
  require 'windows/unicode'
2
- include Windows
2
+ require 'windows/security'
3
3
 
4
4
  module Windows
5
5
  module File
6
6
  include Windows::Unicode
7
+ include Windows::Security
7
8
 
8
9
  API.auto_namespace = 'Windows::File'
9
10
  API.auto_constant = true
@@ -15,6 +16,7 @@ module Windows
15
16
  FILE_END = 2
16
17
 
17
18
  # File Attributes
19
+
18
20
  FILE_ATTRIBUTE_READONLY = 0x00000001
19
21
  FILE_ATTRIBUTE_HIDDEN = 0x00000002
20
22
  FILE_ATTRIBUTE_SYSTEM = 0x00000004
@@ -30,52 +32,24 @@ module Windows
30
32
  FILE_ATTRIBUTE_NOT_CONTENT_INDEXED = 0x00002000
31
33
 
32
34
  # File types
35
+
33
36
  FILE_TYPE_UNKNOWN = 0x0000
34
37
  FILE_TYPE_DISK = 0x0001
35
38
  FILE_TYPE_CHAR = 0x0002
36
39
  FILE_TYPE_PIPE = 0x0003
37
40
  FILE_TYPE_REMOTE = 0x8000
38
41
 
39
- # File security and access rights
40
- APPLICATION_ERROR_MASK = 0x20000000
41
- ERROR_SEVERITY_SUCCESS = 0x00000000
42
- ERROR_SEVERITY_INFORMATIONAL = 0x40000000
43
- ERROR_SEVERITY_WARNING = 0x80000000
44
- ERROR_SEVERITY_ERROR = 0xc0000000
42
+ # File compression constants
43
+
45
44
  COMPRESSION_FORMAT_NONE = 0
46
45
  COMPRESSION_FORMAT_DEFAULT = 1
47
46
  COMPRESSION_FORMAT_LZNT1 = 2
48
47
  COMPRESSION_ENGINE_STANDARD = 0
49
48
  COMPRESSION_ENGINE_MAXIMUM = 256
50
- ACCESS_ALLOWED_ACE_TYPE = 0
51
- ACCESS_DENIED_ACE_TYPE = 1
52
49
  ANYSIZE_ARRAY = 1
53
- SYSTEM_AUDIT_ACE_TYPE = 2
54
- SYSTEM_ALARM_ACE_TYPE = 3
55
- OBJECT_INHERIT_ACE = 1
56
- CONTAINER_INHERIT_ACE = 2
57
- NO_PROPAGATE_INHERIT_ACE = 4
58
- INHERIT_ONLY_ACE = 8
59
- VALID_INHERIT_FLAGS = 16
60
- SUCCESSFUL_ACCESS_ACE_FLAG = 64
61
- FAILED_ACCESS_ACE_FLAG = 128
62
- DELETE = 0x00010000
63
- READ_CONTROL = 0x20000
64
- WRITE_DAC = 0x40000
65
- WRITE_OWNER = 0x80000
66
- SYNCHRONIZE = 0x100000
67
- STANDARD_RIGHTS_REQUIRED = 0xf0000
68
- STANDARD_RIGHTS_READ = 0x20000
69
- STANDARD_RIGHTS_WRITE = 0x20000
70
- STANDARD_RIGHTS_EXECUTE = 0x20000
71
- STANDARD_RIGHTS_ALL = 0x1f0000
72
- SPECIFIC_RIGHTS_ALL = 0xffff
73
- ACCESS_SYSTEM_SECURITY = 0x1000000
74
- MAXIMUM_ALLOWED = 0x2000000
75
- GENERIC_READ = 0x80000000
76
- GENERIC_WRITE = 0x40000000
77
- GENERIC_EXECUTE = 0x20000000
78
- GENERIC_ALL = 0x10000000
50
+
51
+ # File security and access rights
52
+
79
53
  FILE_READ_DATA = 1
80
54
  FILE_LIST_DIRECTORY = 1
81
55
  FILE_WRITE_DATA = 2
@@ -93,7 +67,7 @@ module Windows
93
67
  FILE_READ_ATTRIBUTES = 128
94
68
  FILE_WRITE_ATTRIBUTES = 256
95
69
 
96
- FILE_ALL_ACCESS = STANDARD_RIGHTS_REQUIRED | SYNCHRONIZE | 0x1ff
70
+ FILE_ALL_ACCESS = STANDARD_RIGHTS_REQUIRED | SYNCHRONIZE | 0x1FF
97
71
 
98
72
  FILE_GENERIC_READ =
99
73
  STANDARD_RIGHTS_READ |
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module FileMapping
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module FileSystem
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module GDI
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module GDI
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module GDI
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module Handle
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module Library
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module Memory
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module MSVCRT
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module MSVCRT
@@ -9,8 +8,8 @@ module Windows
9
8
  API.auto_constant = true
10
9
  API.auto_unicode = false
11
10
 
12
- API.new('_chdir', 'P', 'I', MSVCRT_DLL)
13
- API.new('_wchdir', 'P', 'I', MSVCRT_DLL)
11
+ API.new('_chdir', 'S', 'I', MSVCRT_DLL)
12
+ API.new('_wchdir', 'S', 'I', MSVCRT_DLL)
14
13
  API.new('_chdrive', 'I', 'I', MSVCRT_DLL)
15
14
  API.new('_getcwd', 'PI', 'P', MSVCRT_DLL)
16
15
  API.new('_wgetcwd', 'PI', 'P', MSVCRT_DLL)
@@ -19,12 +18,12 @@ module Windows
19
18
  API.new('_getdiskfree', 'IP', 'I', MSVCRT_DLL)
20
19
  API.new('_getdrive', 'V', 'I', MSVCRT_DLL)
21
20
  API.new('_getdrives', 'V', 'L', MSVCRT_DLL)
22
- API.new('_mkdir', 'P', 'I', MSVCRT_DLL)
23
- API.new('_wmkdir', 'P', 'I', MSVCRT_DLL)
24
- API.new('_rmdir', 'P', 'I', MSVCRT_DLL)
25
- API.new('_wrmdir', 'P', 'I', MSVCRT_DLL)
26
- API.new('_searchenv', 'PPP', 'V', MSVCRT_DLL)
27
- API.new('_wsearchenv', 'PPP', 'V', MSVCRT_DLL)
21
+ API.new('_mkdir', 'S', 'I', MSVCRT_DLL)
22
+ API.new('_wmkdir', 'S', 'I', MSVCRT_DLL)
23
+ API.new('_rmdir', 'S', 'I', MSVCRT_DLL)
24
+ API.new('_wrmdir', 'S', 'I', MSVCRT_DLL)
25
+ API.new('_searchenv', 'SSP', 'V', MSVCRT_DLL)
26
+ API.new('_wsearchenv', 'SSP', 'V', MSVCRT_DLL)
28
27
  end
29
28
  end
30
29
  end
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module MSVCRT
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  # This module includes stream I/O, low level I/O, etc.
5
4
  module Windows
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module MSVCRT
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module MSVCRT
@@ -1,5 +1,4 @@
1
1
  require 'windows/api'
2
- include Windows
3
2
 
4
3
  module Windows
5
4
  module National