Commit 0f361b80 authored by Austin English's avatar Austin English Committed by Alexandre Julliard

uxtheme: Fix a compiler warning.

parent dfb8b664
...@@ -685,9 +685,9 @@ static BOOL parse_handle_color_property (struct PARSECOLORSTATE* state, ...@@ -685,9 +685,9 @@ static BOOL parse_handle_color_property (struct PARSECOLORSTATE* state,
{ {
int r,g,b; int r,g,b;
LPCWSTR lpValueEnd = lpValue + dwValueLen; LPCWSTR lpValueEnd = lpValue + dwValueLen;
MSSTYLES_GetNextInteger(lpValue, lpValueEnd, &lpValue, &r); if(MSSTYLES_GetNextInteger(lpValue, lpValueEnd, &lpValue, &r) &&
MSSTYLES_GetNextInteger(lpValue, lpValueEnd, &lpValue, &g); MSSTYLES_GetNextInteger(lpValue, lpValueEnd, &lpValue, &g) &&
if(MSSTYLES_GetNextInteger(lpValue, lpValueEnd, &lpValue, &b)) { MSSTYLES_GetNextInteger(lpValue, lpValueEnd, &lpValue, &b)) {
state->colorElements[state->colorCount] = iPropertyId - TMT_FIRSTCOLOR; state->colorElements[state->colorCount] = iPropertyId - TMT_FIRSTCOLOR;
state->colorRgb[state->colorCount++] = RGB(r,g,b); state->colorRgb[state->colorCount++] = RGB(r,g,b);
switch (iPropertyId) switch (iPropertyId)
...@@ -1210,8 +1210,14 @@ HRESULT MSSTYLES_GetPropertyColor(PTHEME_PROPERTY tp, COLORREF *pColor) ...@@ -1210,8 +1210,14 @@ HRESULT MSSTYLES_GetPropertyColor(PTHEME_PROPERTY tp, COLORREF *pColor)
lpCur = tp->lpValue; lpCur = tp->lpValue;
lpEnd = tp->lpValue + tp->dwValueLen; lpEnd = tp->lpValue + tp->dwValueLen;
MSSTYLES_GetNextInteger(lpCur, lpEnd, &lpCur, &red); if(!MSSTYLES_GetNextInteger(lpCur, lpEnd, &lpCur, &red)) {
MSSTYLES_GetNextInteger(lpCur, lpEnd, &lpCur, &green); TRACE("Could not parse color property\n");
return E_PROP_ID_UNSUPPORTED;
}
if(!MSSTYLES_GetNextInteger(lpCur, lpEnd, &lpCur, &green)) {
TRACE("Could not parse color property\n");
return E_PROP_ID_UNSUPPORTED;
}
if(!MSSTYLES_GetNextInteger(lpCur, lpEnd, &lpCur, &blue)) { if(!MSSTYLES_GetNextInteger(lpCur, lpEnd, &lpCur, &blue)) {
TRACE("Could not parse color property\n"); TRACE("Could not parse color property\n");
return E_PROP_ID_UNSUPPORTED; return E_PROP_ID_UNSUPPORTED;
...@@ -1316,7 +1322,10 @@ HRESULT MSSTYLES_GetPropertyPosition(PTHEME_PROPERTY tp, POINT *pPoint) ...@@ -1316,7 +1322,10 @@ HRESULT MSSTYLES_GetPropertyPosition(PTHEME_PROPERTY tp, POINT *pPoint)
LPCWSTR lpCur = tp->lpValue; LPCWSTR lpCur = tp->lpValue;
LPCWSTR lpEnd = tp->lpValue + tp->dwValueLen; LPCWSTR lpEnd = tp->lpValue + tp->dwValueLen;
MSSTYLES_GetNextInteger(lpCur, lpEnd, &lpCur, &x); if(!MSSTYLES_GetNextInteger(lpCur, lpEnd, &lpCur, &x)) {
TRACE("Could not parse position property\n");
return E_PROP_ID_UNSUPPORTED;
}
if(!MSSTYLES_GetNextInteger(lpCur, lpEnd, &lpCur, &y)) { if(!MSSTYLES_GetNextInteger(lpCur, lpEnd, &lpCur, &y)) {
TRACE("Could not parse position property\n"); TRACE("Could not parse position property\n");
return E_PROP_ID_UNSUPPORTED; return E_PROP_ID_UNSUPPORTED;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment