Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Felix Münchhalfen
wine
Commits
000b180a
Commit
000b180a
authored
23 years ago
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
23 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Added GetComputerNameEx[AW] semi-stub.
parent
5320a42a
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
dlls/kernel/kernel32.spec
+3
-0
3 additions, 0 deletions
dlls/kernel/kernel32.spec
include/winbase.h
+20
-3
20 additions, 3 deletions
include/winbase.h
win32/init.c
+25
-4
25 additions, 4 deletions
win32/init.c
with
48 additions
and
7 deletions
dlls/kernel/kernel32.spec
+
3
−
0
View file @
000b180a
...
...
@@ -226,6 +226,7 @@ debug_channels (comm console debugstr dll int resource stress thunk toolhelp
@ stdcall DebugBreak() DebugBreak
@ stdcall DefineDosDeviceA(long str str) DefineDosDeviceA
@ stub DefineDosDeviceW
@ stub DelayLoadFailureHook
@ stdcall DeleteAtom(long) DeleteAtom
@ forward DeleteCriticalSection ntdll.RtlDeleteCriticalSection
@ stdcall DeleteFileA(str) DeleteFileA
...
...
@@ -336,6 +337,8 @@ debug_channels (comm console debugstr dll int resource stress thunk toolhelp
@ stdcall GetCompressedFileSizeA(long ptr) GetCompressedFileSizeA
@ stdcall GetCompressedFileSizeW(long ptr) GetCompressedFileSizeW
@ stdcall GetComputerNameA(ptr ptr) GetComputerNameA
@ stdcall GetComputerNameExA(long ptr ptr) GetComputerNameExA
@ stdcall GetComputerNameExW(long ptr ptr) GetComputerNameExW
@ stdcall GetComputerNameW(ptr ptr) GetComputerNameW
@ stdcall GetConsoleCP() GetConsoleCP
@ stdcall GetConsoleCursorInfo(long ptr) GetConsoleCursorInfo
...
...
This diff is collapsed.
Click to expand it.
include/winbase.h
+
20
−
3
View file @
000b180a
...
...
@@ -977,7 +977,20 @@ typedef struct tagCOMMTIMEOUTS {
typedef
void
CALLBACK
(
*
PAPCFUNC
)(
ULONG_PTR
);
typedef
void
CALLBACK
(
*
PTIMERAPCROUTINE
)(
LPVOID
,
DWORD
,
DWORD
);
typedef
enum
_COMPUTER_NAME_FORMAT
{
ComputerNameNetBIOS
,
ComputerNameDnsHostname
,
ComputerNameDnsDomain
,
ComputerNameDnsFullyQualified
,
ComputerNamePhysicalNetBIOS
,
ComputerNamePhysicalDnsHostname
,
ComputerNamePhysicalDnsDomain
,
ComputerNamePhysicalDnsFullyQualified
,
ComputerNameMax
}
COMPUTER_NAME_FORMAT
;
/*DWORD WINAPI GetVersion( void );*/
BOOL
WINAPI
GetVersionExA
(
OSVERSIONINFOA
*
);
BOOL
WINAPI
GetVersionExW
(
OSVERSIONINFOW
*
);
...
...
@@ -1063,6 +1076,7 @@ BOOL WINAPI BuildCommDCBAndTimeoutsW(LPCWSTR,LPDCB,LPCOMMTIMEOUTS);
#define BuildCommDCBAndTimeouts WINELIB_NAME_AW(BuildCommDCBAndTimeouts)
BOOL
WINAPI
CancelIo
(
HANDLE
);
BOOL
WINAPI
CancelWaitableTimer
(
HANDLE
);
BOOL
WINAPI
CheckTokenMembership
(
HANDLE
,
PSID
,
PBOOL
);
BOOL
WINAPI
ClearCommBreak
(
HANDLE
);
BOOL
WINAPI
ClearCommError
(
HANDLE
,
LPDWORD
,
LPCOMSTAT
);
BOOL
WINAPI
ClearEventLogA
(
HANDLE
,
LPCSTR
);
...
...
@@ -1179,9 +1193,12 @@ BOOL WINAPI GetCommTimeouts(HANDLE,LPCOMMTIMEOUTS);
LPSTR
WINAPI
GetCommandLineA
(
void
);
LPWSTR
WINAPI
GetCommandLineW
(
void
);
#define GetCommandLine WINELIB_NAME_AW(GetCommandLine)
BOOL
WINAPI
GetComputerNameA
(
LPSTR
,
LPDWORD
);
BOOL
WINAPI
GetComputerNameW
(
LPWSTR
,
LPDWORD
);
BOOL
WINAPI
GetComputerNameA
(
LPSTR
,
LPDWORD
);
BOOL
WINAPI
GetComputerNameW
(
LPWSTR
,
LPDWORD
);
#define GetComputerName WINELIB_NAME_AW(GetComputerName)
BOOL
WINAPI
GetComputerNameExA
(
COMPUTER_NAME_FORMAT
,
LPSTR
,
LPDWORD
);
BOOL
WINAPI
GetComputerNameExW
(
COMPUTER_NAME_FORMAT
,
LPWSTR
,
LPDWORD
);
#define GetComputerNameEx WINELIB_NAME_AW(GetComputerNameEx)
HANDLE
WINAPI
GetCurrentProcess
(
void
);
HANDLE
WINAPI
GetCurrentThread
(
void
);
BOOL
WINAPI
GetDefaultCommConfigA
(
LPCSTR
,
LPCOMMCONFIG
,
LPDWORD
);
...
...
This diff is collapsed.
Click to expand it.
win32/init.c
+
25
−
4
View file @
000b180a
...
...
@@ -8,6 +8,8 @@
#include
<string.h>
#include
<unistd.h>
#include
<stdlib.h>
#include
<errno.h>
#include
"winnls.h"
#include
"winbase.h"
#include
"winerror.h"
...
...
@@ -33,9 +35,16 @@ BOOL WINAPI GetComputerNameA(LPSTR name,LPDWORD size)
BOOL
ret
;
__TRY
{
ret
=
(
-
1
!=
gethostname
(
name
,
*
size
));
if
(
ret
)
*
size
=
strlen
(
name
);
char
host_name
[
256
];
TRACE
(
"*size = %ld
\n
"
,
*
size
);
ret
=
(
gethostname
(
host_name
,
sizeof
(
host_name
))
!=
-
1
);
if
(
ret
)
{
lstrcpynA
(
name
,
host_name
,
*
size
);
*
size
=
strlen
(
name
);
}
else
WARN
(
"gethostname: %s
\n
"
,
strerror
(
errno
));
}
__EXCEPT
(
page_fault
)
{
...
...
@@ -43,7 +52,8 @@ BOOL WINAPI GetComputerNameA(LPSTR name,LPDWORD size)
return
FALSE
;
}
__ENDTRY
TRACE
(
"returning (%ld) %s
\n
"
,
*
size
,
debugstr_a
(
name
));
return
ret
;
}
...
...
@@ -60,3 +70,14 @@ BOOL WINAPI GetComputerNameW(LPWSTR name,LPDWORD size)
return
ret
;
}
BOOL
WINAPI
GetComputerNameExA
(
COMPUTER_NAME_FORMAT
type
,
LPSTR
name
,
LPDWORD
size
)
{
FIXME
(
"(%d, %p, %p) semi-stub!
\n
"
,
type
,
name
,
size
);
return
GetComputerNameA
(
name
,
size
);
}
BOOL
WINAPI
GetComputerNameExW
(
COMPUTER_NAME_FORMAT
type
,
LPWSTR
name
,
LPDWORD
size
)
{
FIXME
(
"(%d, %p, %p) semi-stub!
\n
"
,
type
,
name
,
size
);
return
GetComputerNameW
(
name
,
size
);
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment