[Gdiplus 5/6] test_getgenerics: bring in line with test_fontfamily in both variable names and avoiding the extra pointer deref
Adam Petaccia
adam at tpetaccia.com
Fri Jun 27 19:15:09 CDT 2008
---
dlls/gdiplus/tests/font.c | 24 +++++++++++-------------
1 files changed, 11 insertions(+), 13 deletions(-)
diff --git a/dlls/gdiplus/tests/font.c b/dlls/gdiplus/tests/font.c
index c9ebaff..4c3e9df 100644
--- a/dlls/gdiplus/tests/font.c
+++ b/dlls/gdiplus/tests/font.c
@@ -187,42 +187,40 @@ static void test_fontfamily (void)
static void test_getgenerics (void)
{
GpStatus stat;
- GpFontFamily** family;
+ GpFontFamily* FontFamily;
WCHAR familyName[LF_FACESIZE];
ZeroMemory(familyName, sizeof(familyName)/sizeof(WCHAR));
- family = GdipAlloc (sizeof (GpFontFamily*));
-
- stat = GdipGetGenericFontFamilySansSerif (family);
+ stat = GdipGetGenericFontFamilySansSerif (&FontFamily);
expect (Ok, stat);
- stat = GdipGetFamilyName (*family, familyName, LANG_NEUTRAL);
+ stat = GdipGetFamilyName (FontFamily, familyName, LANG_NEUTRAL);
expect (Ok, stat);
ok ((lstrcmpiW(familyName, MicrosoftSansSerif) == 0) ||
(lstrcmpiW(familyName,MSSansSerif) == 0),
"Expected Microsoft Sans Serif or MS Sans Serif, got %s\n",
debugstr_w(familyName));
- stat = GdipDeleteFontFamily (*family);
+ stat = GdipDeleteFontFamily (FontFamily);
expect (Ok, stat);
- stat = GdipGetGenericFontFamilySerif (family);
+ stat = GdipGetGenericFontFamilySerif (&FontFamily);
expect (Ok, stat);
- stat = GdipGetFamilyName (*family, familyName, LANG_NEUTRAL);
+ stat = GdipGetFamilyName (FontFamily, familyName, LANG_NEUTRAL);
expect (Ok, stat);
ok (lstrcmpiW(familyName, TimesNewRoman) == 0,
"Expected Times New Roman, got %s\n", debugstr_w(familyName));
- stat = GdipDeleteFontFamily (*family);
+ stat = GdipDeleteFontFamily (FontFamily);
expect (Ok, stat);
- stat = GdipGetGenericFontFamilyMonospace (family);
+ stat = GdipGetGenericFontFamilyMonospace (&FontFamily);
expect (Ok, stat);
- stat = GdipGetFamilyName (*family, familyName, LANG_NEUTRAL);
+ stat = GdipGetFamilyName (FontFamily, familyName, LANG_NEUTRAL);
expect (Ok, stat);
ok (lstrcmpiW(familyName, CourierNew) == 0,
"Expected Courier New, got %s\n", debugstr_w(familyName));
- stat = GdipDeleteFontFamily (*family);
+ stat = GdipDeleteFontFamily (FontFamily);
expect (Ok, stat);
- GdipFree (family);
+ GdipFree (FontFamily);
}
START_TEST(font)
--
1.5.4.3
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://www.winehq.org/pipermail/wine-patches/attachments/20080627/02119485/attachment.pgp
More information about the wine-patches
mailing list