tracker issue : CF-3848011

select a category, or use search below
(searches all categories and all time range)

[ANeff] Bug for: <cfzip action="zip" recurse="yes" storepath="no"> does not recurse

| View in Tracker

Status/Resolution/Reason: Closed/Fixed/

Reporter/Name(from Bugbase): Aaron Neff / Aaron Neff (Aaron Neff)

Created: 11/05/2014

Components: File Management, CFZip

Versions: 11.0

Failure Type: Data Loss

Found In Build/Fixed In Build: CF11_Final / CF11 Update5

Priority/Frequency: Critical / Some users will encounter

Locale/System: English / Win All

Vote Count: 0

Listed in the version Issues Fixed doc
<cfzip action="zip" recurse="yes" storepath="no"> does not recurse


  if(!directoryExists(expandPath('./cfzip_source'))) {
  if(!directoryExists(expandPath('./cfzip_source/subdir'))) {
  if(!fileExists(expandPath('./cfzip_source/file1.txt'))) {
	  fileWrite(expandPath('./cfzip_source/file1.txt'), "file 1");
  if(!fileExists(expandPath('./cfzip_source/subdir/file2.txt'))) {
	  fileWrite(expandPath('./cfzip_source/subdir/file2.txt'), "file 2");
  if(fileExists(expandPath('./'))) {
<cfzip source="#expandPath('./cfzip_source')#" file="#expandPath('./')#" storepath="no" />
<cfzip action="list" name="q" file="#expandPath('./')#" showdirectory="yes" />
<cfdump var="#q#" />

Actual result: Dumps a 1-row query containing the file1.txt file.

Expected result: Dumps a 3-row query containing the file1.txt and file2.txt files and the subdir directory.

Related ticket: 3795400.

----------------------------- Additional Watson Details -----------------------------

Watson Bug ID:	3848011

External Customer Info:
External Company:  
External Customer Name: itisdesign
External Customer Email:



Since storepath="no" breaks recurse="yes", developers may not know subdirectories are not currently being included into the .zip. So I think this is an important issue. Data loss is occurring right now whenever the original directories/files are deleted after the .zip is created. Thanks!, -Aaron
Comment by External U.
10251 | November 10, 2014 04:47:08 AM GMT
The fix for this bug is available in the pre-release build of ColdFusion 11 Update 5
Comment by CFwatson U.
10252 | February 20, 2015 09:25:15 AM GMT
Verified this is fixed in CF11 Update 5 (build 11,0,05,293506). Thanks!, -Aaron
Comment by External U.
10253 | November 19, 2015 03:39:06 AM GMT