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
b9fc3f8e
Commit
b9fc3f8e
authored
Apr 18, 2006
by
James Hawkins
Committed by
Alexandre Julliard
Apr 19, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
advpack: Set the destination directory to the working directory if key equals SourceDir.
parent
fc52a848
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
4 deletions
+10
-4
advpack.c
dlls/advpack/advpack.c
+10
-4
No files found.
dlls/advpack/advpack.c
View file @
b9fc3f8e
...
...
@@ -92,7 +92,7 @@ static void get_dest_dir(HINF hInf, PCWSTR pszSection, PWSTR pszBuffer, DWORD dw
}
/* loads the LDIDs specified in the install section of an INF */
static
void
set_ldids
(
HINF
hInf
,
LPCWSTR
pszInstallSection
)
static
void
set_ldids
(
HINF
hInf
,
LPCWSTR
pszInstallSection
,
LPCWSTR
pszWorkingDir
)
{
WCHAR
field
[
MAX_FIELD_LENGTH
];
WCHAR
line
[
MAX_FIELD_LENGTH
];
...
...
@@ -101,6 +101,8 @@ static void set_ldids(HINF hInf, LPCWSTR pszInstallSection)
DWORD
size
;
int
ldid
;
static
const
WCHAR
source_dir
[]
=
{
'S'
,
'o'
,
'u'
,
'r'
,
'c'
,
'e'
,
'D'
,
'i'
,
'r'
,
0
};
static
const
WCHAR
custDestW
[]
=
{
'C'
,
'u'
,
's'
,
't'
,
'o'
,
'm'
,
'D'
,
'e'
,
's'
,
't'
,
'i'
,
'n'
,
'a'
,
't'
,
'i'
,
'o'
,
'n'
,
0
};
...
...
@@ -145,7 +147,11 @@ static void set_ldids(HINF hInf, LPCWSTR pszInstallSection)
if
(
ptr
)
*
ptr
=
'\0'
;
get_dest_dir
(
hInf
,
value
,
dest
,
MAX_PATH
);
/* set dest to pszWorkingDir if key is SourceDir */
if
(
pszWorkingDir
&&
!
lstrcmpiW
(
value
,
source_dir
))
lstrcpynW
(
dest
,
pszWorkingDir
,
MAX_PATH
);
else
get_dest_dir
(
hInf
,
value
,
dest
,
MAX_PATH
);
/* set all ldids to dest */
while
((
ptr
=
get_parameter
(
&
key
,
','
)))
...
...
@@ -359,7 +365,7 @@ HRESULT WINAPI OpenINFEngineW(LPCWSTR pszInfFilename, LPCWSTR pszInstallSection,
if
(
*
phInf
==
INVALID_HANDLE_VALUE
)
return
HRESULT_FROM_WIN32
(
ERROR_FILE_NOT_FOUND
);
set_ldids
(
*
phInf
,
pszInstallSection
);
set_ldids
(
*
phInf
,
pszInstallSection
,
NULL
);
return
S_OK
;
}
...
...
@@ -717,7 +723,7 @@ HRESULT WINAPI TranslateInfStringW(LPCWSTR pszInfFilename, LPCWSTR pszInstallSec
if
(
hInf
==
INVALID_HANDLE_VALUE
)
return
HRESULT_FROM_WIN32
(
ERROR_FILE_NOT_FOUND
);
set_ldids
(
hInf
,
pszInstallSection
);
set_ldids
(
hInf
,
pszInstallSection
,
NULL
);
if
(
!
SetupGetLineTextW
(
NULL
,
hInf
,
pszTranslateSection
,
pszTranslateKey
,
pszBuffer
,
dwBufferSize
,
pdwRequiredSize
))
...
...
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