From 48ed7797f6e4010c874863f5c72153671b3c39af Mon Sep 17 00:00:00 2001 From: Matthew Fernandez Date: Sun, 20 Mar 2022 21:33:21 -0700 Subject: [PATCH] lib/glcomp: remove some open coded 'NULL' --- lib/glcomp/glcompbutton.c | 2 +- lib/glcomp/glcomppanel.c | 4 ++-- lib/glcomp/glcompset.c | 2 +- lib/glcomp/glpangofont.c | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/glcomp/glcompbutton.c b/lib/glcomp/glcompbutton.c index cf359761e..d81fbd345 100644 --- a/lib/glcomp/glcompbutton.c +++ b/lib/glcomp/glcompbutton.c @@ -61,7 +61,7 @@ glCompButton *glCompButtonNew(glCompObj * par, GLfloat x, GLfloat y, p->label->common.font->justify.HJustify = glFontHJustifyCenter; p->label->common.align = glAlignParent; /*image */ - p->image = (glCompImage *) 0; + p->image = NULL; p->glyphPos = glButtonGlyphLeft; return p; } diff --git a/lib/glcomp/glcomppanel.c b/lib/glcomp/glcomppanel.c index cc231e35f..df533dfec 100644 --- a/lib/glcomp/glcomppanel.c +++ b/lib/glcomp/glcomppanel.c @@ -34,9 +34,9 @@ glCompPanel *glCompPanelNew(glCompObj * parentObj, GLfloat x, GLfloat y, p->common.height = h; p->common.font = glNewFontFromParent((glCompObj *) p, NULL); - p->text = (char *) 0; + p->text = NULL; p->common.functions.draw = (glcompdrawfunc_t)glCompPanelDraw; - p->image = (glCompImage *) 0; + p->image = NULL; return p; } void glCompSetPanelText(glCompPanel * p, char *t) diff --git a/lib/glcomp/glcompset.c b/lib/glcomp/glcompset.c index e3cfd2126..7cb222560 100644 --- a/lib/glcomp/glcompset.c +++ b/lib/glcomp/glcompset.c @@ -207,7 +207,7 @@ glCompSet *glCompSetNew(int w, int h) s->objcnt = 0; s->obj = NULL; s->textureCount = 0; - s->textures = (glCompTex **) 0; + s->textures = NULL; s->common.font = glNewFontFromParent((glCompObj *) s, NULL); s->common.compset = (glCompSet *) s; s->common.functions.mouseover = (glcompmouseoverfunc_t)glCompMouseMove; diff --git a/lib/glcomp/glpangofont.c b/lib/glcomp/glpangofont.c index 8eb77e102..2da2109d9 100644 --- a/lib/glcomp/glpangofont.c +++ b/lib/glcomp/glpangofont.c @@ -56,7 +56,7 @@ static PangoLayout *get_pango_layout(char *markup_text, if (!pango_parse_markup (markup_text, -1, '\0', &attr_list, &text, NULL, NULL)) - return (PangoLayout *) 0; + return NULL; layout = pango_layout_new(context); pango_layout_set_text(layout, text, -1); pango_layout_set_font_description(layout, desc); -- 2.40.0