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
be874f1a
Commit
be874f1a
authored
Mar 04, 2008
by
Ove Kaaven
Committed by
Alexandre Julliard
Mar 07, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msi: Fix bug in handling of multivolume CAB files.
parent
76e08969
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
89 additions
and
0 deletions
+89
-0
files.c
dlls/msi/files.c
+3
-0
install.c
dlls/msi/tests/install.c
+86
-0
No files found.
dlls/msi/files.c
View file @
be874f1a
...
...
@@ -401,10 +401,13 @@ static INT_PTR cabinet_notify(FDINOTIFICATIONTYPE fdint, PFDINOTIFICATION pfdin)
}
case
fdintCLOSE_FILE_INFO
:
{
CabData
*
data
=
(
CabData
*
)
pfdin
->
pv
;
FILETIME
ft
;
FILETIME
ftLocal
;
HANDLE
handle
=
(
HANDLE
)
pfdin
->
hf
;
data
->
mi
->
is_continuous
=
FALSE
;
if
(
!
DosDateTimeToFileTime
(
pfdin
->
date
,
pfdin
->
time
,
&
ft
))
return
-
1
;
if
(
!
LocalFileTimeToFileTime
(
&
ft
,
&
ftLocal
))
...
...
dlls/msi/tests/install.c
View file @
be874f1a
...
...
@@ -175,6 +175,13 @@ static const CHAR cc_component_dat[] = "Component\tComponentId\tDirectory_\tAttr
"augustus
\t\t
MSITESTDIR
\t
0
\t
1
\t
augustus
\n
"
"caesar
\t\t
MSITESTDIR
\t
0
\t
1
\t
caesar
\n
"
;
static
const
CHAR
cc2_component_dat
[]
=
"Component
\t
ComponentId
\t
Directory_
\t
Attributes
\t
Condition
\t
KeyPath
\n
"
"s72
\t
S38
\t
s72
\t
i2
\t
S255
\t
S72
\n
"
"Component
\t
Component
\n
"
"maximus
\t\t
MSITESTDIR
\t
0
\t
1
\t
maximus
\n
"
"augustus
\t\t
MSITESTDIR
\t
0
\t
0
\t
augustus
\n
"
"caesar
\t\t
MSITESTDIR
\t
0
\t
1
\t
caesar
\n
"
;
static
const
CHAR
cc_feature_dat
[]
=
"Feature
\t
Feature_Parent
\t
Title
\t
Description
\t
Display
\t
Level
\t
Directory_
\t
Attributes
\n
"
"s38
\t
S38
\t
L64
\t
L255
\t
I2
\t
i2
\t
S72
\t
i2
\n
"
"Feature
\t
Feature
\n
"
...
...
@@ -194,6 +201,14 @@ static const CHAR cc_file_dat[] = "File\tComponent_\tFileName\tFileSize\tVersion
"augustus
\t
augustus
\t
augustus
\t
50000
\t\t\t
16384
\t
2
\n
"
"caesar
\t
caesar
\t
caesar
\t
500
\t\t\t
16384
\t
12"
;
static
const
CHAR
cc2_file_dat
[]
=
"File
\t
Component_
\t
FileName
\t
FileSize
\t
Version
\t
Language
\t
Attributes
\t
Sequence
\n
"
"s72
\t
s72
\t
l255
\t
i4
\t
S72
\t
S20
\t
I2
\t
i2
\n
"
"File
\t
File
\n
"
"maximus
\t
maximus
\t
maximus
\t
500
\t\t\t
16384
\t
1
\n
"
"augustus
\t
augustus
\t
augustus
\t
50000
\t\t\t
16384
\t
2
\n
"
"tiberius
\t
maximus
\t
tiberius
\t
500
\t\t\t
16384
\t
3
\n
"
"caesar
\t
caesar
\t
caesar
\t
500
\t\t\t
16384
\t
12"
;
static
const
CHAR
cc_media_dat
[]
=
"DiskId
\t
LastSequence
\t
DiskPrompt
\t
Cabinet
\t
VolumeLabel
\t
Source
\n
"
"i2
\t
i4
\t
L64
\t
S255
\t
S32
\t
S72
\n
"
"Media
\t
DiskId
\n
"
...
...
@@ -624,6 +639,18 @@ static const msi_table cc_tables[] =
ADD_TABLE
(
property
),
};
static
const
msi_table
cc2_tables
[]
=
{
ADD_TABLE
(
cc2_component
),
ADD_TABLE
(
directory
),
ADD_TABLE
(
cc_feature
),
ADD_TABLE
(
cc_feature_comp
),
ADD_TABLE
(
cc2_file
),
ADD_TABLE
(
install_exec_seq
),
ADD_TABLE
(
cc_media
),
ADD_TABLE
(
property
),
};
static
const
msi_table
co_tables
[]
=
{
ADD_TABLE
(
cc_component
),
...
...
@@ -1538,6 +1565,49 @@ static void create_cc_test_files(void)
DeleteFile
(
"caesar"
);
}
static
void
create_cc2_test_files
(
void
)
{
CCAB
cabParams
;
HFCI
hfci
;
ERF
erf
;
static
CHAR
cab_context
[]
=
"test%d.cab"
;
BOOL
res
;
create_file
(
"maximus"
,
500
);
create_file
(
"augustus"
,
50000
);
create_file
(
"tiberius"
,
500
);
create_file
(
"caesar"
,
500
);
set_cab_parameters
(
&
cabParams
,
"test1.cab"
,
40000
);
hfci
=
FCICreate
(
&
erf
,
file_placed
,
mem_alloc
,
mem_free
,
fci_open
,
fci_read
,
fci_write
,
fci_close
,
fci_seek
,
fci_delete
,
get_temp_file
,
&
cabParams
,
cab_context
);
ok
(
hfci
!=
NULL
,
"Failed to create an FCI context
\n
"
);
res
=
add_file
(
hfci
,
"maximus"
,
tcompTYPE_NONE
);
ok
(
res
,
"Failed to add file maximus
\n
"
);
res
=
add_file
(
hfci
,
"augustus"
,
tcompTYPE_NONE
);
ok
(
res
,
"Failed to add file augustus
\n
"
);
res
=
add_file
(
hfci
,
"tiberius"
,
tcompTYPE_NONE
);
ok
(
res
,
"Failed to add file tiberius
\n
"
);
res
=
FCIFlushCabinet
(
hfci
,
FALSE
,
get_next_cabinet
,
progress
);
ok
(
res
,
"Failed to flush the cabinet
\n
"
);
res
=
FCIDestroy
(
hfci
);
ok
(
res
,
"Failed to destroy the cabinet
\n
"
);
create_cab_file
(
"test3.cab"
,
MEDIA_SIZE
,
"caesar
\0
"
);
DeleteFile
(
"maximus"
);
DeleteFile
(
"augustus"
);
DeleteFile
(
"tiberius"
);
DeleteFile
(
"caesar"
);
}
static
void
delete_cab_files
(
void
)
{
SHFILEOPSTRUCT
shfl
;
...
...
@@ -1577,6 +1647,22 @@ static void test_continuouscabs(void)
delete_cab_files
();
DeleteFile
(
msifile
);
create_cc2_test_files
();
create_database
(
msifile
,
cc2_tables
,
sizeof
(
cc2_tables
)
/
sizeof
(
msi_table
));
MsiSetInternalUI
(
INSTALLUILEVEL_NONE
,
NULL
);
r
=
MsiInstallProductA
(
msifile
,
NULL
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %u
\n
"
,
r
);
ok
(
delete_pf
(
"msitest
\\
maximus"
,
TRUE
),
"File not installed
\n
"
);
ok
(
!
delete_pf
(
"msitest
\\
augustus"
,
TRUE
),
"File installed
\n
"
);
ok
(
delete_pf
(
"msitest
\\
tiberius"
,
TRUE
),
"File not installed
\n
"
);
ok
(
delete_pf
(
"msitest
\\
caesar"
,
TRUE
),
"File not installed
\n
"
);
ok
(
delete_pf
(
"msitest"
,
FALSE
),
"File not installed
\n
"
);
delete_cab_files
();
DeleteFile
(
msifile
);
}
static
void
test_caborder
(
void
)
...
...
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