and wrap the zero-length regex displaying code in a HAVE_REGEX_H #define

git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1602 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
This commit is contained in:
David Lawrence Ramsey 2003-12-24 08:29:49 +00:00
parent 76c4b33ef4
commit 2a4ab6d29d

View File

@ -2236,10 +2236,12 @@ void do_replace_highlight(int highlight_flag, const char *word)
if (highlight_flag)
wattron(edit, A_REVERSE);
#ifdef HAVE_REGEX_H
/* This is so we can show zero-length regexes. */
if (word_len == 0)
waddstr(edit, " ");
else
#endif
waddnstr(edit, word, y - 1);
if (word_len > y)