summaryrefslogtreecommitdiff
path: root/src/util.c
diff options
context:
space:
mode:
authorMatthieu Herrb <matthieu.herrb@laas.fr>2013-11-02 15:32:40 +0100
committerMatthieu Herrb <matthieu.herrb@laas.fr>2013-11-02 15:32:40 +0100
commit8c2c913fee87d96eebaf7fc88a325c2dd27074a8 (patch)
tree3150ade56abc2e91747b6c2e34368491e6560dd3 /src/util.c
parentfdf60fe3c0169fa168321deb1a2ccd188ee384f8 (diff)
parent9c09c3e3577460fcef44e7abe51d22fcbda10ea8 (diff)
Merge remote-tracking branch 'origin/master' into obsd
Conflicts: src/session.c src/util.c
Diffstat (limited to 'src/util.c')
-rw-r--r--src/util.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/util.c b/src/util.c
index 5a53a59..e54eca8 100644
--- a/src/util.c
+++ b/src/util.c
@@ -391,7 +391,7 @@ InsertRGBColormap (Atom a, XStandardColormap *maps, int nmaps, Bool replace)
}
if (!sc) { /* no existing, allocate new */
- sc = (StdCmap *) malloc (sizeof (StdCmap));
+ sc = malloc (sizeof (StdCmap));
if (!sc) {
fprintf (stderr, "%s: unable to allocate %ld bytes for StdCmap\n",
ProgramName, (unsigned long)sizeof (StdCmap));
@@ -400,7 +400,7 @@ InsertRGBColormap (Atom a, XStandardColormap *maps, int nmaps, Bool replace)
}
if (replace) { /* just update contents */
- if (sc->maps) XFree ((char *) maps);
+ if (sc->maps) XFree (maps);
if (sc == Scr->StdCmapInfo.mru) Scr->StdCmapInfo.mru = NULL;
} else { /* else appending */
sc->next = NULL;
@@ -429,7 +429,7 @@ RemoveRGBColormap (Atom a)
prev = sc;
}
if (sc) { /* found one */
- if (sc->maps) XFree ((char *) sc->maps);
+ if (sc->maps) XFree (sc->maps);
if (prev) prev->next = sc->next;
if (Scr->StdCmapInfo.head == sc) Scr->StdCmapInfo.head = sc->next;
if (Scr->StdCmapInfo.tail == sc) Scr->StdCmapInfo.tail = prev;
@@ -455,7 +455,7 @@ LocateStandardColormaps(void)
InsertRGBColormap (atoms[i], maps, nmaps, False);
}
}
- if (atoms) XFree ((char *) atoms);
+ if (atoms) XFree (atoms);
return;
}