Skip to content

Commit fe7066a

Browse files
dschogitster
authored andcommitted
clar: stop including shellapi.h unnecessarily
The `shellapi.h` header was included as of clar-test/clar@136e763211aa, to have `SHFileOperation()` declared so that it could be called. However, clar-test/clar@5ce31b69b525 removed that call, and therefore that `#include <shellapi.h>` is unnecessary. It is also unwanted in Git because this project uses a subset of Git for Windows' SDK in its CI builds that (for bandwidth reasons) excludes tons of header files, including `shellapi.h`. So let's remove it. Note: Since the `windows.h` header would include `shellapi.h` anyway, we also define `WIN32_LEAN_AND_MEAN` to avoid this and similar other unnecessary includes before including `windows.h`. Signed-off-by: Johannes Schindelin <[email protected]> Signed-off-by: Patrick Steinhardt <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 7d83563 commit fe7066a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

t/unit-tests/clar/clar.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@
1919
#include <sys/stat.h>
2020

2121
#ifdef _WIN32
22+
# define WIN32_LEAN_AND_MEAN
2223
# include <windows.h>
2324
# include <io.h>
24-
# include <shellapi.h>
2525
# include <direct.h>
2626

2727
# define _MAIN_CC __cdecl

0 commit comments

Comments
 (0)