Re: [PATCH v5 2/5] read-cache: load cache extensions on a worker thread
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Sep 17, 2018, 21:32 UTC
- Message-ID
- <xmqqh8in6c98.fsf@gitster-ct.c.googlers.com>
- In-Reply-To
- <CACsJy8ATsS6S5zib2FqJf1stPcGwSTO1qYBSz514Xu2GfJ4Apw@mail.gmail.com>
Duy Nguyen <pclouds@gmail.com> writes:
Show 18 quoted lines
>> diff --git a/read-cache.c b/read-cache.c >> index 858935f123..b203eebb44 100644 >> --- a/read-cache.c >> +++ b/read-cache.c >> @@ -23,6 +23,10 @@ >> #include "split-index.h" >> #include "utf8.h" >> #include "fsmonitor.h" >> +#ifndef NO_PTHREADS >> +#include <pthread.h> >> +#include <thread-utils.h> >> +#endif > > I don't think you're supposed to include system header files after > "cache.h". Including thread-utils.h should be enough (and it keeps the > exception of inclduing pthread.h in just one place). Please use > "pthread-utils.h" instead of <pthread-utils.h> which is usually for > system header files. And include ptherad-utils.h unconditionally.
All correct except for s/p\(thread-utils\)/\1/g; Sorry for missing this during my earlier review.
Thanks.