(get_preceding_char): If POS is zero, always call
authorhanda <handa>
Fri, 27 Oct 2006 12:15:11 +0000 (12:15 +0000)
committerhanda <handa>
Fri, 27 Oct 2006 12:15:11 +0000 (12:15 +0000)
get_surrounding_text.

src/input.c

index 9338c3c..6834bae 100644 (file)
@@ -547,7 +547,7 @@ get_preceding_char (MInputContext *ic, int pos)
   MText *mt;
   int len;
 
-  if (ic_info->preceding_text)
+  if (pos && ic_info->preceding_text)
     {
       len = mtext_nchars (ic_info->preceding_text);
       if (pos <= len)