Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
0f9bc1d3
Commit
0f9bc1d3
authored
May 03, 2009
by
Nikolay Sivov
Committed by
Alexandre Julliard
May 04, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32: Check header pointer in CreateDIBitmap.
parent
1b1e0027
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
0 deletions
+7
-0
dib.c
dlls/gdi32/dib.c
+2
-0
bitmap.c
dlls/gdi32/tests/bitmap.c
+5
-0
No files found.
dlls/gdi32/dib.c
View file @
0f9bc1d3
...
...
@@ -1097,6 +1097,8 @@ HBITMAP WINAPI CreateDIBitmap( HDC hdc, const BITMAPINFOHEADER *header,
DWORD
compr
,
size
;
DC
*
dc
;
if
(
!
header
)
return
0
;
if
(
DIB_GetBitmapInfo
(
header
,
&
width
,
&
height
,
&
planes
,
&
bpp
,
&
compr
,
&
size
)
==
-
1
)
return
0
;
if
(
width
<
0
)
...
...
dlls/gdi32/tests/bitmap.c
View file @
0f9bc1d3
...
...
@@ -145,6 +145,11 @@ static void test_createdibitmap(void)
bmih
.
biBitCount
=
32
;
bmih
.
biCompression
=
BI_RGB
;
hbm
=
CreateDIBitmap
(
hdc
,
NULL
,
CBM_INIT
,
NULL
,
NULL
,
0
);
ok
(
hbm
==
NULL
,
"CreateDIBitmap should fail
\n
"
);
hbm
=
CreateDIBitmap
(
hdc
,
NULL
,
0
,
NULL
,
NULL
,
0
);
ok
(
hbm
==
NULL
,
"CreateDIBitmap should fail
\n
"
);
/* First create an un-initialised bitmap. The depth of the bitmap
should match that of the hdc and not that supplied in bmih.
*/
...
...
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