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
b0dcf32b
Commit
b0dcf32b
authored
Apr 11, 2013
by
Piotr Caban
Committed by
Alexandre Julliard
Apr 11, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
oleaut32: Make typeinfo offsets table dynamic.
parent
5e6016e2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
1 deletion
+18
-1
typelib2.c
dlls/oleaut32/typelib2.c
+18
-1
No files found.
dlls/oleaut32/typelib2.c
View file @
b0dcf32b
...
...
@@ -178,7 +178,8 @@ typedef struct tagICreateTypeLib2Impl
int
typelib_guids
;
/* Number of defined typelib guids */
int
typeinfo_guids
;
/* Number of defined typeinfo guids */
INT
typelib_typeinfo_offsets
[
0x200
];
/* Hope that's enough. */
INT
*
typelib_typeinfo_offsets
;
int
typeinfo_offsets_size
;
INT
*
typelib_namehash_segment
;
INT
*
typelib_guidhash_segment
;
...
...
@@ -621,6 +622,21 @@ static int ctl2_alloc_typeinfo(
int
offset
;
MSFT_TypeInfoBase
*
typeinfo
;
if
(
!
This
->
typeinfo_offsets_size
)
{
This
->
typelib_typeinfo_offsets
=
heap_alloc
(
8
*
sizeof
(
INT
));
if
(
!
This
->
typelib_typeinfo_offsets
)
return
-
1
;
This
->
typeinfo_offsets_size
=
8
;
}
else
if
(
This
->
typelib_header
.
nrtypeinfos
==
This
->
typeinfo_offsets_size
)
{
INT
*
new_offsets
=
heap_realloc
(
This
->
typelib_typeinfo_offsets
,
2
*
This
->
typeinfo_offsets_size
*
sizeof
(
INT
));
if
(
!
new_offsets
)
return
-
1
;
This
->
typelib_typeinfo_offsets
=
new_offsets
;
This
->
typeinfo_offsets_size
*=
2
;
}
offset
=
ctl2_alloc_segment
(
This
,
MSFT_SEG_TYPEINFO
,
sizeof
(
MSFT_TypeInfoBase
),
0
);
if
(
offset
==
-
1
)
return
-
1
;
...
...
@@ -4338,6 +4354,7 @@ static ULONG WINAPI ICreateTypeLib2_fnRelease(ICreateTypeLib2 *iface)
heap_free
(
This
->
typelib_segment_data
[
i
]);
This
->
typelib_segment_data
[
i
]
=
NULL
;
}
heap_free
(
This
->
typelib_typeinfo_offsets
);
SysFreeString
(
This
->
filename
);
This
->
filename
=
NULL
;
...
...
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