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
88580113
Commit
88580113
authored
Oct 24, 2006
by
Mike McCormack
Committed by
Alexandre Julliard
Oct 23, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msi: Add the column type INTEGER as an alias for INT.
parent
0d7dc8f9
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
54 additions
and
80 deletions
+54
-80
db.c
dlls/msi/tests/db.c
+51
-79
package.c
dlls/msi/tests/package.c
+1
-1
tokenize.c
dlls/msi/tokenize.c
+2
-0
No files found.
dlls/msi/tests/db.c
View file @
88580113
...
...
@@ -2810,55 +2810,43 @@ static void test_integers(void)
"`five` SHORT NOT NULL, `six` INT NOT NULL, "
"`seven` INTEGER NOT NULL, `eight` LONG NOT NULL "
"PRIMARY KEY `one`)"
;
todo_wine
{
r
=
MsiDatabaseOpenView
(
hdb
,
query
,
&
view
);
ok
(
r
==
ERROR_SUCCESS
,
"MsiDatabaseOpenView failed
\n
"
);
r
=
MsiViewExecute
(
view
,
0
);
ok
(
r
==
ERROR_SUCCESS
,
"MsiViewExecute failed
\n
"
);
r
=
MsiViewClose
(
view
);
ok
(
r
==
ERROR_SUCCESS
,
"MsiViewClose failed
\n
"
);
}
r
=
MsiDatabaseOpenView
(
hdb
,
query
,
&
view
);
ok
(
r
==
ERROR_SUCCESS
,
"MsiDatabaseOpenView failed
\n
"
);
r
=
MsiViewExecute
(
view
,
0
);
ok
(
r
==
ERROR_SUCCESS
,
"MsiViewExecute failed
\n
"
);
r
=
MsiViewClose
(
view
);
ok
(
r
==
ERROR_SUCCESS
,
"MsiViewClose failed
\n
"
);
r
=
MsiCloseHandle
(
view
);
ok
(
r
==
ERROR_SUCCESS
,
"MsiCloseHandle failed
\n
"
);
query
=
"SELECT * FROM `integers`"
;
r
=
MsiDatabaseOpenView
(
hdb
,
query
,
&
view
);
todo_wine
{
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
}
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
r
=
MsiViewGetColumnInfo
(
view
,
MSICOLINFO_NAMES
,
&
rec
);
count
=
MsiRecordGetFieldCount
(
rec
);
todo_wine
{
ok
(
count
==
8
,
"Expected 8, got %d
\n
"
,
count
);
ok
(
check_record
(
rec
,
1
,
"one"
),
"Expected one
\n
"
);
ok
(
check_record
(
rec
,
2
,
"two"
),
"Expected two
\n
"
);
ok
(
check_record
(
rec
,
3
,
"three"
),
"Expected three
\n
"
);
ok
(
check_record
(
rec
,
4
,
"four"
),
"Expected four
\n
"
);
ok
(
check_record
(
rec
,
5
,
"five"
),
"Expected five
\n
"
);
ok
(
check_record
(
rec
,
6
,
"six"
),
"Expected six
\n
"
);
ok
(
check_record
(
rec
,
7
,
"seven"
),
"Expected seven
\n
"
);
ok
(
check_record
(
rec
,
8
,
"eight"
),
"Expected eight
\n
"
);
}
ok
(
count
==
8
,
"Expected 8, got %d
\n
"
,
count
);
ok
(
check_record
(
rec
,
1
,
"one"
),
"Expected one
\n
"
);
ok
(
check_record
(
rec
,
2
,
"two"
),
"Expected two
\n
"
);
ok
(
check_record
(
rec
,
3
,
"three"
),
"Expected three
\n
"
);
ok
(
check_record
(
rec
,
4
,
"four"
),
"Expected four
\n
"
);
ok
(
check_record
(
rec
,
5
,
"five"
),
"Expected five
\n
"
);
ok
(
check_record
(
rec
,
6
,
"six"
),
"Expected six
\n
"
);
ok
(
check_record
(
rec
,
7
,
"seven"
),
"Expected seven
\n
"
);
ok
(
check_record
(
rec
,
8
,
"eight"
),
"Expected eight
\n
"
);
MsiCloseHandle
(
rec
);
r
=
MsiViewGetColumnInfo
(
view
,
MSICOLINFO_TYPES
,
&
rec
);
count
=
MsiRecordGetFieldCount
(
rec
);
todo_wine
{
ok
(
count
==
8
,
"Expected 8, got %d
\n
"
,
count
);
ok
(
check_record
(
rec
,
1
,
"I2"
),
"Expected I2
\n
"
);
ok
(
check_record
(
rec
,
2
,
"I2"
),
"Expected I2
\n
"
);
ok
(
check_record
(
rec
,
3
,
"I2"
),
"Expected I2
\n
"
);
ok
(
check_record
(
rec
,
4
,
"I4"
),
"Expected I4
\n
"
);
ok
(
check_record
(
rec
,
5
,
"i2"
),
"Expected i2
\n
"
);
ok
(
check_record
(
rec
,
6
,
"i2"
),
"Expected i2
\n
"
);
ok
(
check_record
(
rec
,
7
,
"i2"
),
"Expected i2
\n
"
);
ok
(
check_record
(
rec
,
8
,
"i4"
),
"Expected i4
\n
"
);
}
ok
(
count
==
8
,
"Expected 8, got %d
\n
"
,
count
);
ok
(
check_record
(
rec
,
1
,
"I2"
),
"Expected I2
\n
"
);
ok
(
check_record
(
rec
,
2
,
"I2"
),
"Expected I2
\n
"
);
ok
(
check_record
(
rec
,
3
,
"I2"
),
"Expected I2
\n
"
);
ok
(
check_record
(
rec
,
4
,
"I4"
),
"Expected I4
\n
"
);
ok
(
check_record
(
rec
,
5
,
"i2"
),
"Expected i2
\n
"
);
ok
(
check_record
(
rec
,
6
,
"i2"
),
"Expected i2
\n
"
);
ok
(
check_record
(
rec
,
7
,
"i2"
),
"Expected i2
\n
"
);
ok
(
check_record
(
rec
,
8
,
"i4"
),
"Expected i4
\n
"
);
MsiCloseHandle
(
rec
);
MsiViewClose
(
view
);
...
...
@@ -2867,23 +2855,17 @@ static void test_integers(void)
/* insert values into it, NULL where NOT NULL is specified */
query
=
"INSERT INTO `integers` ( `one`, `two`, `three`, `four`, `five`, `six`, `seven`, `eight` )"
"VALUES('', '', '', '', '', '', '', '')"
;
todo_wine
{
r
=
MsiDatabaseOpenView
(
hdb
,
query
,
&
view
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
r
=
MsiViewExecute
(
view
,
0
);
ok
(
r
==
ERROR_FUNCTION_FAILED
,
"Expected ERROR_FUNCTION_FAILED, got %d
\n
"
,
r
);
}
r
=
MsiDatabaseOpenView
(
hdb
,
query
,
&
view
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
r
=
MsiViewExecute
(
view
,
0
);
ok
(
r
==
ERROR_FUNCTION_FAILED
,
"Expected ERROR_FUNCTION_FAILED, got %d
\n
"
,
r
);
MsiViewClose
(
view
);
MsiCloseHandle
(
view
);
query
=
"SELECT * FROM `integers`"
;
r
=
do_query
(
hdb
,
query
,
&
rec
);
todo_wine
{
ok
(
r
==
ERROR_NO_MORE_ITEMS
,
"Expected ERROR_NO_MORE_ITEMS, got %d
\n
"
,
r
);
}
ok
(
r
==
ERROR_NO_MORE_ITEMS
,
"Expected ERROR_NO_MORE_ITEMS, got %d
\n
"
,
r
);
r
=
MsiRecordGetFieldCount
(
rec
);
ok
(
r
==
-
1
,
"record count wrong: %d
\n
"
,
r
);
...
...
@@ -2893,46 +2875,36 @@ static void test_integers(void)
/* insert legitimate values into it */
query
=
"INSERT INTO `integers` ( `one`, `two`, `three`, `four`, `five`, `six`, `seven`, `eight` )"
"VALUES('', '2', '', '4', '5', '6', '7', '8')"
;
todo_wine
{
r
=
MsiDatabaseOpenView
(
hdb
,
query
,
&
view
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
r
=
MsiViewExecute
(
view
,
0
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
}
r
=
MsiDatabaseOpenView
(
hdb
,
query
,
&
view
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
r
=
MsiViewExecute
(
view
,
0
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
query
=
"SELECT * FROM `integers`"
;
r
=
do_query
(
hdb
,
query
,
&
rec
);
todo_wine
{
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
}
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
r
=
MsiRecordGetFieldCount
(
rec
);
todo_wine
{
ok
(
r
==
8
,
"record count wrong: %d
\n
"
,
r
);
}
ok
(
r
==
8
,
"record count wrong: %d
\n
"
,
r
);
todo_wine
{
i
=
MsiRecordGetInteger
(
rec
,
1
);
ok
(
i
==
0x80000000
,
"Expected 0x80000000
, got %d
\n
"
,
i
);
ok
(
i
==
MSI_NULL_INTEGER
,
"Expected MSI_NULL_INTEGER
, got %d
\n
"
,
i
);
i
=
MsiRecordGetInteger
(
rec
,
3
);
ok
(
i
==
0x80000000
,
"Expected 0x80000000, got %d
\n
"
,
i
);
todo_wine
{
i
=
MsiRecordGetInteger
(
rec
,
2
);
ok
(
i
==
2
,
"Expected 2, got %d
\n
"
,
i
);
i
=
MsiRecordGetInteger
(
rec
,
4
);
ok
(
i
==
4
,
"Expected 4, got %d
\n
"
,
i
);
i
=
MsiRecordGetInteger
(
rec
,
5
);
ok
(
i
==
5
,
"Expected 5, got %d
\n
"
,
i
);
i
=
MsiRecordGetInteger
(
rec
,
6
);
ok
(
i
==
6
,
"Expected 6, got %d
\n
"
,
i
);
i
=
MsiRecordGetInteger
(
rec
,
7
);
ok
(
i
==
7
,
"Expected 7, got %d
\n
"
,
i
);
i
=
MsiRecordGetInteger
(
rec
,
8
);
ok
(
i
==
8
,
"Expected 8, got %d
\n
"
,
i
);
ok
(
i
==
MSI_NULL_INTEGER
,
"Expected MSI_NULL_INTEGER, got %d
\n
"
,
i
);
}
i
=
MsiRecordGetInteger
(
rec
,
2
);
ok
(
i
==
2
,
"Expected 2, got %d
\n
"
,
i
);
i
=
MsiRecordGetInteger
(
rec
,
4
);
ok
(
i
==
4
,
"Expected 4, got %d
\n
"
,
i
);
i
=
MsiRecordGetInteger
(
rec
,
5
);
ok
(
i
==
5
,
"Expected 5, got %d
\n
"
,
i
);
i
=
MsiRecordGetInteger
(
rec
,
6
);
ok
(
i
==
6
,
"Expected 6, got %d
\n
"
,
i
);
i
=
MsiRecordGetInteger
(
rec
,
7
);
ok
(
i
==
7
,
"Expected 7, got %d
\n
"
,
i
);
i
=
MsiRecordGetInteger
(
rec
,
8
);
ok
(
i
==
8
,
"Expected 8, got %d
\n
"
,
i
);
MsiCloseHandle
(
rec
);
MsiViewClose
(
view
);
...
...
dlls/msi/tests/package.c
View file @
88580113
...
...
@@ -1418,13 +1418,13 @@ static void test_msipackage(void)
r
=
try_query
(
hdb
,
query
);
ok
(
r
==
ERROR_SUCCESS
,
"failed to create Properties table
\n
"
);
todo_wine
{
query
=
"CREATE TABLE `InstallExecuteSequence` ("
"`Action` CHAR(72), `Condition` CHAR(0), `Sequence` INTEGER "
"PRIMARY KEY `Action`)"
;
r
=
try_query
(
hdb
,
query
);
ok
(
r
==
ERROR_SUCCESS
,
"failed to create InstallExecuteSequence table
\n
"
);
todo_wine
{
sprintf
(
name
,
"#%ld"
,
hdb
);
r
=
MsiOpenPackage
(
name
,
&
hpack
);
ok
(
r
==
ERROR_INSTALL_PACKAGE_INVALID
,
"MsiOpenPackage returned wrong code
\n
"
);
...
...
dlls/msi/tokenize.c
View file @
88580113
...
...
@@ -94,6 +94,7 @@ static const WCHAR INNER_W[] = { 'I','N','N','E','R',0 };
static
const
WCHAR
INSERT_W
[]
=
{
'I'
,
'N'
,
'S'
,
'E'
,
'R'
,
'T'
,
0
};
static
const
WCHAR
INSTEAD_W
[]
=
{
'I'
,
'N'
,
'S'
,
'T'
,
'E'
,
'A'
,
'D'
,
0
};
static
const
WCHAR
INT_W
[]
=
{
'I'
,
'N'
,
'T'
,
0
};
static
const
WCHAR
INTEGER_W
[]
=
{
'I'
,
'N'
,
'T'
,
'E'
,
'G'
,
'E'
,
'R'
,
0
};
static
const
WCHAR
INTERSECT_W
[]
=
{
'I'
,
'N'
,
'T'
,
'E'
,
'R'
,
'S'
,
'E'
,
'C'
,
'T'
,
0
};
static
const
WCHAR
INTO_W
[]
=
{
'I'
,
'N'
,
'T'
,
'O'
,
0
};
static
const
WCHAR
IS_W
[]
=
{
'I'
,
'S'
,
0
};
...
...
@@ -206,6 +207,7 @@ static const Keyword aKeywordTable[] = {
{
INSERT_W
,
TK_INSERT
},
{
INSTEAD_W
,
TK_INSTEAD
},
{
INT_W
,
TK_INT
},
{
INTEGER_W
,
TK_INT
},
{
INTERSECT_W
,
TK_INTERSECT
},
{
INTO_W
,
TK_INTO
},
{
IS_W
,
TK_IS
},
...
...
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