mirror of
https://github.com/reactos/reactos.git
synced 2025-05-07 02:41:22 +00:00
[GDI32] MirrorRgnByWidth(): Fix 'phrgn' parameter handling
Detected by Cppcheck: uselessAssignmentPtrArg. Addendum to794e7aa
(r31523) ande647530
(r65893).
This commit is contained in:
parent
fb023adf5a
commit
5f076e5558
1 changed files with 6 additions and 3 deletions
|
@ -85,7 +85,7 @@ FASTCALL
|
||||||
MirrorRgnByWidth(
|
MirrorRgnByWidth(
|
||||||
_In_ HRGN hrgn,
|
_In_ HRGN hrgn,
|
||||||
_In_ INT Width,
|
_In_ INT Width,
|
||||||
_In_ HRGN *phrgn)
|
_Out_opt_ HRGN *phrgn)
|
||||||
{
|
{
|
||||||
INT cRgnDSize, Ret = 0;
|
INT cRgnDSize, Ret = 0;
|
||||||
PRGNDATA pRgnData;
|
PRGNDATA pRgnData;
|
||||||
|
@ -118,7 +118,10 @@ MirrorRgnByWidth(
|
||||||
hRgnex = ExtCreateRegion(NULL, cRgnDSize , pRgnData);
|
hRgnex = ExtCreateRegion(NULL, cRgnDSize , pRgnData);
|
||||||
if (hRgnex)
|
if (hRgnex)
|
||||||
{
|
{
|
||||||
if (phrgn) phrgn = (HRGN *)hRgnex;
|
if (phrgn)
|
||||||
|
{
|
||||||
|
*phrgn = hRgnex;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
CombineRgn(hrgn, hRgnex, 0, RGN_COPY);
|
CombineRgn(hrgn, hRgnex, 0, RGN_COPY);
|
||||||
|
@ -138,7 +141,7 @@ WINAPI
|
||||||
MirrorRgnDC(
|
MirrorRgnDC(
|
||||||
_In_ HDC hdc,
|
_In_ HDC hdc,
|
||||||
_In_ HRGN hrgn,
|
_In_ HRGN hrgn,
|
||||||
_In_ HRGN *phrn)
|
_Out_opt_ HRGN *phrn)
|
||||||
{
|
{
|
||||||
if (!GdiValidateHandle((HGDIOBJ) hdc) ||
|
if (!GdiValidateHandle((HGDIOBJ) hdc) ||
|
||||||
(GDI_HANDLE_GET_TYPE(hdc) != GDI_OBJECT_TYPE_DC))
|
(GDI_HANDLE_GET_TYPE(hdc) != GDI_OBJECT_TYPE_DC))
|
||||||
|
|
Loading…
Reference in a new issue