Index: commands.c
===================================================================
--- commands.c	(revision d2fd2f78682e126efa7f07750844446b4746a5dc)
+++ commands.c	(revision 118c9199a27438cd95333d4ef3faa2ccddab6622)
@@ -2553,8 +2553,9 @@
     
   if (argc==1 || (argc==2 && !strcmp(argv[1], "-r"))) {
-    owl_function_search_helper(OWL_SEARCH_CONTINUE, direction);
+    /* When continuing a search, don't consider the current message. */
+    owl_function_search_helper(false, direction);
   } else {
     owl_function_set_search(buffstart);
-    owl_function_search_helper(OWL_SEARCH_MATCH_CURRENT, direction);
+    owl_function_search_helper(true, direction);
   }
   
Index: functions.c
===================================================================
--- functions.c	(revision 4a41f1621e8d6055c8a4ac848f34ea1acbf0ba0e)
+++ functions.c	(revision 118c9199a27438cd95333d4ef3faa2ccddab6622)
@@ -2894,5 +2894,5 @@
 }
 
-void owl_function_search_helper(int mode, int direction)
+void owl_function_search_helper(int consider_current, int direction)
 {
   /* move to a message that contains the string.  If direction is
@@ -2900,5 +2900,5 @@
    * OWL_DIRECTION_UPWARDS then search backwards.
    *
-   * If mode is OWL_SEARCH_MATCH_CURRENT then it will stay on the
+   * If consider_current is true then it will stay on the
    * current message if it contains the string.
    */
@@ -2917,5 +2917,5 @@
   }
 
-  if (mode == OWL_SEARCH_MATCH_CURRENT) {
+  if (consider_current) {
     start=curmsg;
   } else if (direction==OWL_DIRECTION_DOWNWARDS) {
Index: owl.h
===================================================================
--- owl.h	(revision 1b8c3f80e370e8256036bafef98acc094a2c34aa)
+++ owl.h	(revision 118c9199a27438cd95333d4ef3faa2ccddab6622)
@@ -138,7 +138,4 @@
 #define OWL_DIRECTION_DOWNWARDS 1
 #define OWL_DIRECTION_UPWARDS   2
-
-#define OWL_SEARCH_MATCH_CURRENT 0
-#define OWL_SEARCH_CONTINUE      1
 
 #define OWL_LOGGING_DIRECTION_BOTH 0
Index: viewwin.c
===================================================================
--- viewwin.c	(revision 4a41f1621e8d6055c8a4ac848f34ea1acbf0ba0e)
+++ viewwin.c	(revision 118c9199a27438cd95333d4ef3faa2ccddab6622)
@@ -144,5 +144,5 @@
 char *owl_viewwin_command_search(owl_viewwin *v, int argc, const char *const *argv, const char *buff)
 {
-  int direction, mode;
+  int direction, consider_current;
   const char *buffstart;
 
@@ -155,11 +155,11 @@
 
   if (argc==1 || (argc==2 && !strcmp(argv[1], "-r"))) {
-    mode = OWL_SEARCH_CONTINUE;
+    consider_current = false;
   } else {
     owl_function_set_search(buffstart);
-    mode = OWL_SEARCH_MATCH_CURRENT;
-  }
-
-  if (!owl_viewwin_search(v, owl_global_get_search_re(&g), mode, direction))
+    consider_current = true;
+  }
+
+  if (!owl_viewwin_search(v, owl_global_get_search_re(&g), consider_current, direction))
     owl_function_error("No more matches");
   return NULL;
@@ -177,5 +177,5 @@
   owl_function_set_search(line);
   if (!owl_viewwin_search(data->v, owl_global_get_search_re(&g),
-			  OWL_SEARCH_MATCH_CURRENT, data->direction))
+			  true, data->direction))
     owl_function_error("No matches");
 }
@@ -368,8 +368,8 @@
  * found.
  *
- * If mode is OWL_SEARCH_MATCH_CURRENT then stay on the current line
+ * If consider_current is true then stay on the current line
  * if it matches.
  */
-int owl_viewwin_search(owl_viewwin *v, const owl_regex *re, int mode, int direction)
+int owl_viewwin_search(owl_viewwin *v, const owl_regex *re, int consider_current, int direction)
 {
   int start, end, offset;
@@ -379,5 +379,5 @@
   if (direction == OWL_DIRECTION_DOWNWARDS) {
     offset = owl_fmtext_search(&v->fmtext, re,
-			       (mode == OWL_SEARCH_CONTINUE) ? end : start);
+			       consider_current ? start : end);
     if (offset < 0)
       return 0;
@@ -391,5 +391,5 @@
      * them. */
     buf = owl_fmtext_get_text(&v->fmtext);
-    lineend = (mode == OWL_SEARCH_CONTINUE) ? start : end;
+    lineend = consider_current ? end : start;
     while (lineend > 0) {
       linestartp = memrchr(buf, '\n', lineend - 1);
