Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
c710a50b
Commit
c710a50b
authored
Nov 06, 2013
by
Frédéric Delanoy
Committed by
Alexandre Julliard
Nov 07, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ctapi32: Use BOOL type where appropriate.
parent
1a89ea70
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
ctapi32.c
dlls/ctapi32/ctapi32.c
+6
-6
No files found.
dlls/ctapi32/ctapi32.c
View file @
c710a50b
...
...
@@ -42,13 +42,13 @@ static IS8 (*pCT_close)(IU16 ctn) = NULL;
static
void
*
ctapi_handle
=
NULL
;
static
int
load_functions
(
void
)
{
static
BOOL
load_functions
(
void
)
{
char
soname
[
MAX_PATH
]
=
FALLBACK_LIBCTAPI
,
buffer
[
MAX_PATH
];
LONG
result
;
HKEY
key_handle
;
if
(
pCT_init
)
/* loaded already */
return
0
;
return
TRUE
;
/* Try to get name of low level library from registry */
/* @@ Wine registry key: HKCU\Software\Wine\ctapi32 */
...
...
@@ -80,16 +80,16 @@ static int load_functions(void) {
MESSAGE
(
"Wine cannot find any usable hardware library, ctapi32.dll not working.
\n
"
);
MESSAGE
(
"Please create the key
\"
HKEY_CURRENT_USER
\\
Software
\\
Wine
\\
ctapi32
\"
in your registry
\n
"
);
MESSAGE
(
"and set the value
\"
library
\"
to your library name (e.g.
\"
libctapi-cyberjack.so.1
\"
or
\"
/usr/lib/readers/libctapi.so
\"
).
\n
"
);
return
1
;
return
FALSE
;
}
#define LOAD_FUNCPTR(f) if((p##f = wine_dlsym(ctapi_handle, #f, NULL, 0)) == NULL){WARN("Can't find symbol %s\n", #f); return
1
;}
#define LOAD_FUNCPTR(f) if((p##f = wine_dlsym(ctapi_handle, #f, NULL, 0)) == NULL){WARN("Can't find symbol %s\n", #f); return
FALSE
;}
LOAD_FUNCPTR
(
CT_init
);
LOAD_FUNCPTR
(
CT_data
);
LOAD_FUNCPTR
(
CT_close
);
#undef LOAD_FUNCPTR
return
0
;
return
TRUE
;
}
/*
...
...
@@ -129,7 +129,7 @@ BOOL WINAPI DllMain (HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
case
DLL_PROCESS_ATTACH
:
DisableThreadLibraryCalls
(
hinstDLL
);
/* Try to load low-level library */
if
(
load_functions
()
!=
0
)
if
(
!
load_functions
()
)
return
FALSE
;
/* error */
break
;
case
DLL_PROCESS_DETACH
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment