Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
4335c464
Commit
4335c464
authored
Aug 17, 2015
by
Hugh McMaster
Committed by
Alexandre Julliard
Aug 18, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
uninstaller: Output Unicode program names in CLI mode.
parent
7bde6ec4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
15 deletions
+11
-15
main.c
programs/uninstaller/main.c
+11
-15
No files found.
programs/uninstaller/main.c
View file @
4335c464
...
...
@@ -21,7 +21,6 @@
*
*/
#include <stdio.h>
#include <string.h>
#include <windows.h>
#include <shlwapi.h>
...
...
@@ -92,30 +91,27 @@ static void __cdecl output_message(unsigned int id, ...)
__ms_va_end
(
va_args
);
}
static
void
__cdecl
output_array
(
WCHAR
*
fmt
,
...)
{
__ms_va_list
va_args
;
__ms_va_start
(
va_args
,
fmt
);
output_formatstring
(
fmt
,
va_args
);
__ms_va_end
(
va_args
);
}
/**
* Used to output program list when used with --list
*/
static
void
ListUninstallPrograms
(
void
)
{
unsigned
int
i
;
int
lenDescr
,
lenKey
;
char
*
descr
;
char
*
key
;
static
WCHAR
fmtW
[]
=
{
'%'
,
'1'
,
'|'
,
'|'
,
'|'
,
'%'
,
'2'
,
'\n'
,
0
};
FetchUninstallInformation
();
for
(
i
=
0
;
i
<
numentries
;
i
++
)
{
lenDescr
=
WideCharToMultiByte
(
CP_UNIXCP
,
0
,
entries
[
i
].
descr
,
-
1
,
NULL
,
0
,
NULL
,
NULL
);
lenKey
=
WideCharToMultiByte
(
CP_UNIXCP
,
0
,
entries
[
i
].
key
,
-
1
,
NULL
,
0
,
NULL
,
NULL
);
descr
=
HeapAlloc
(
GetProcessHeap
(),
0
,
lenDescr
);
key
=
HeapAlloc
(
GetProcessHeap
(),
0
,
lenKey
);
WideCharToMultiByte
(
CP_UNIXCP
,
0
,
entries
[
i
].
descr
,
-
1
,
descr
,
lenDescr
,
NULL
,
NULL
);
WideCharToMultiByte
(
CP_UNIXCP
,
0
,
entries
[
i
].
key
,
-
1
,
key
,
lenKey
,
NULL
,
NULL
);
printf
(
"%s|||%s
\n
"
,
key
,
descr
);
HeapFree
(
GetProcessHeap
(),
0
,
descr
);
HeapFree
(
GetProcessHeap
(),
0
,
key
);
}
output_array
(
fmtW
,
entries
[
i
].
key
,
entries
[
i
].
descr
);
}
...
...
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