Skip to content

Commit 02c0f25

Browse files
committed
It is bad to recursively remove every CVS directory in a person's
home directory. Bad bad bad. Make sure the variable was set to something before cd-ing to blank and ending up in their $HOME. Also, since each line under a make rule is treated as a new subshell, it's not necessary to surround the whole line in ()s. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93766 13f79535-47bb-0310-9956-ffa450edef68
1 parent 1c531d3 commit 02c0f25

1 file changed

Lines changed: 7 additions & 7 deletions

File tree

Makefile.in

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -110,25 +110,25 @@ install-htdocs:
110110
@test -d $(htdocs-srcdir) && (cd $(htdocs-srcdir) && cp -rp * $(htdocsdir))
111111
@test -d $(manualdir) || $(MKINSTALLDIRS) $(manualdir)
112112
@test -d $(top_srcdir)/docs/manual && (cd $(top_srcdir)/docs/manual && cp -rp * $(manualdir))
113-
@(cd $(htdocsdir) && find . -name "CVS" -print | xargs rm -rf {} \;)
113+
@test "x$(htdocsdir)" != "x" && cd $(htdocsdir) && find . -name "CVS" -print | xargs rm -rf {} \;
114114

115115
install-error:
116116
@echo Installing error documents
117117
@test -d $(errordir) || $(MKINSTALLDIRS) $(errordir)
118-
@(cd $(top_srcdir)/docs/error && cp -rp * $(errordir))
119-
@(cd $(errordir) && find . -name "CVS" -print | xargs rm -rf {} \;)
118+
@cd $(top_srcdir)/docs/error && cp -rp * $(errordir)
119+
@test "x$(errordir)" != "x" && cd $(errordir) && find . -name "CVS" -print | xargs rm -rf {} \;
120120

121121
install-icons:
122122
@echo Installing icons
123123
@test -d $(iconsdir) || $(MKINSTALLDIRS) $(iconsdir)
124-
@(cd $(top_srcdir)/docs/icons && cp -rp * $(iconsdir))
125-
@(cd $(iconsdir) && find . -name "CVS" -print | xargs rm -rf {} \;)
124+
@cd $(top_srcdir)/docs/icons && cp -rp * $(iconsdir)
125+
@test "x$(iconsdir)" != "x" && cd $(iconsdir) && find . -name "CVS" -print | xargs rm -rf {} \;
126126

127127
install-cgi:
128128
@echo Installing CGIs
129129
@test -d $(cgidir) || $(MKINSTALLDIRS) $(cgidir)
130-
@(cd $(top_srcdir)/docs/cgi-examples && cp -rp * $(cgidir))
131-
@(cd $(cgidir) && find . -name "CVS" -print | xargs rm -rf {} \;)
130+
@cd $(top_srcdir)/docs/cgi-examples && cp -rp * $(cgidir)
131+
@test "x$(cgidir)" != "x" && cd $(cgidir) && find . -name "CVS" -print | xargs rm -rf {} \;
132132

133133
install-other:
134134
@test -d $(logfiledir) || $(MKINSTALLDIRS) $(logfiledir)

0 commit comments

Comments
 (0)