run-command.h: include thread-utils.h instead of pthread.h

run-command.c may use threads for its async support. But instead of
including pthread.h directly, let's include thread-utils.h.

run-command.c probably never needs the dummy bits in thread-utils.h
when NO_PTHREADS is defined. But this makes sure we have consistent
HAVE_THREADS behavior everywhere. From now on outside compat/,
thread-utils.h is the only place that includes pthread.h

Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Nguyễn Thái Ngọc Duy 2018-11-03 09:48:38 +01:00 коммит произвёл Junio C Hamano
Родитель 0ec79358d0
Коммит 10bc232d0f
1 изменённых файлов: 1 добавлений и 3 удалений

Просмотреть файл

@ -1,9 +1,7 @@
#ifndef RUN_COMMAND_H
#define RUN_COMMAND_H
#ifndef NO_PTHREADS
#include <pthread.h>
#endif
#include "thread-utils.h"
#include "argv-array.h"