changeset 2049:0ba755e5dc48

ut_expand_tabs: Check the argument is not null It should never happen, but you never know...
author Mikael Berthe <mikael@lilotux.net>
date Wed, 28 Nov 2012 17:50:25 +0100
parents 349e3c3eb874
children 998feaa54ef0
files mcabber/mcabber/utils.c
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/mcabber/mcabber/utils.c	Tue Nov 27 19:49:50 2012 +0100
+++ b/mcabber/mcabber/utils.c	Wed Nov 28 17:50:25 2012 +0100
@@ -676,6 +676,9 @@
   char *p, *q;
   guint n = 0, bc = 0;
 
+  if (!text)
+    return NULL;
+
   xtext = (char*)text;
   for (p=xtext; *p; p++)
     if (*p == '\t')