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
1740fe0f
Commit
1740fe0f
authored
Apr 06, 2006
by
Mike Hearn
Committed by
Alexandre Julliard
Apr 07, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comctl32: Add OOM codepath in imagelist control.
parent
8122173a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
imagelist.c
dlls/comctl32/imagelist.c
+4
-1
No files found.
dlls/comctl32/imagelist.c
View file @
1740fe0f
...
@@ -1833,6 +1833,7 @@ static HBITMAP _read_bitmap(LPSTREAM pstm,int ilcFlag,int cx,int cy) {
...
@@ -1833,6 +1833,7 @@ static HBITMAP _read_bitmap(LPSTREAM pstm,int ilcFlag,int cx,int cy) {
width
=
bmih
.
biWidth
;
width
=
bmih
.
biWidth
;
height
=
bmih
.
biHeight
;
height
=
bmih
.
biHeight
;
bmihc
=
(
LPBITMAPINFOHEADER
)
LocalAlloc
(
LMEM_ZEROINIT
,
sizeof
(
bmih
)
+
palspace
);
bmihc
=
(
LPBITMAPINFOHEADER
)
LocalAlloc
(
LMEM_ZEROINIT
,
sizeof
(
bmih
)
+
palspace
);
if
(
!
bmihc
)
goto
ret1
;
memcpy
(
bmihc
,
&
bmih
,
sizeof
(
bmih
));
memcpy
(
bmihc
,
&
bmih
,
sizeof
(
bmih
));
longsperline
=
((
width
*
bitsperpixel
+
31
)
&~
0x1f
)
>>
5
;
longsperline
=
((
width
*
bitsperpixel
+
31
)
&~
0x1f
)
>>
5
;
bmihc
->
biSizeImage
=
(
longsperline
*
height
)
<<
2
;
bmihc
->
biSizeImage
=
(
longsperline
*
height
)
<<
2
;
...
@@ -1962,8 +1963,10 @@ HIMAGELIST WINAPI ImageList_Read (LPSTREAM pstm)
...
@@ -1962,8 +1963,10 @@ HIMAGELIST WINAPI ImageList_Read (LPSTREAM pstm)
#endif
#endif
hbmColor
=
_read_bitmap
(
pstm
,
ilHead
.
flags
&
~
ILC_MASK
,
ilHead
.
cx
,
ilHead
.
cy
);
hbmColor
=
_read_bitmap
(
pstm
,
ilHead
.
flags
&
~
ILC_MASK
,
ilHead
.
cx
,
ilHead
.
cy
);
if
(
!
hbmColor
)
if
(
!
hbmColor
)
{
WARN
(
"failed to read bitmap from stream
\n
"
);
return
NULL
;
return
NULL
;
}
if
(
ilHead
.
flags
&
ILC_MASK
)
{
if
(
ilHead
.
flags
&
ILC_MASK
)
{
hbmMask
=
_read_bitmap
(
pstm
,
0
,
ilHead
.
cx
,
ilHead
.
cy
);
hbmMask
=
_read_bitmap
(
pstm
,
0
,
ilHead
.
cx
,
ilHead
.
cy
);
if
(
!
hbmMask
)
{
if
(
!
hbmMask
)
{
...
...
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