sequencer: refactor sequencer_add_exec_commands() to work on a todo_list
[gitweb.git] / grep.c
diff --git a/grep.c b/grep.c
index f6bd89e40b7f7a8442a6e0a302a1e6080df5afbd..0d50598acda6f1c41951d1d656ea701114473239 100644 (file)
--- a/grep.c
+++ b/grep.c
@@ -1513,7 +1513,6 @@ static void show_line(struct grep_opt *opt, char *bol, char *eol,
        }
 }
 
-#ifndef NO_PTHREADS
 int grep_use_locks;
 
 /*
@@ -1539,11 +1538,6 @@ static inline void grep_attr_unlock(void)
  */
 pthread_mutex_t grep_read_mutex;
 
-#else
-#define grep_attr_lock()
-#define grep_attr_unlock()
-#endif
-
 static int match_funcname(struct grep_opt *opt, struct grep_source *gs, char *bol, char *eol)
 {
        xdemitconf_t *xecfg = opt->priv;
@@ -1811,7 +1805,7 @@ static int grep_source_1(struct grep_opt *opt, struct grep_source *gs, int colle
                 * is not thread-safe.
                 */
                grep_attr_lock();
-               textconv = userdiff_get_textconv(gs->driver);
+               textconv = userdiff_get_textconv(opt->repo, gs->driver);
                grep_attr_unlock();
        }