Check-in [355ee88ec8]
Overview
SHA1:355ee88ec8170892bc0a1ae31e45a9fb9389be37
Date: 2015-05-26 15:44:57
User: rkeene
Comment:Fixed bug in resetting latest value
Timelines: family | ancestors | descendants | both | trunk
Downloads: Tarball | ZIP archive
Other Links: files | file ages | folders | manifest
Tags And Properties
Context
2015-05-26
15:45
[1a0a82c686] AppFS 1.8 (user: rkeene, tags: trunk, 1.8)
15:44
[355ee88ec8] Fixed bug in resetting latest value (user: rkeene, tags: trunk)
2015-05-12
13:30
[3021e03379] Updated to be more subtle with differing inodes, only differ them if the files are different (user: rkeene, tags: trunk)
Changes

Modified appfsd.tcl from [9d766a9055] to [a394650d8e].

   381    381   			# Do not do any additional work if we already have this package
   382    382   			set existing_packages [db eval {SELECT package FROM packages WHERE hostname = $hostname AND sha1 = $pkgInfo(hash);}]
   383    383   			if {[lsearch -exact $existing_packages $pkgInfo(package)] != -1} {
   384    384   				continue
   385    385   			}
   386    386   
   387    387   			if {$pkgInfo(isLatest)} {
   388         -				db eval {UPDATE packages SET isLatest = 0 WHERE hostname = $hostname AND package = $pkgInfo($package) AND os = $pkgInfo($package) AND cpuArch = $pkgInfo(cpuArch);}
          388  +				db eval {UPDATE packages SET isLatest = 0 WHERE hostname = $hostname AND package = $pkgInfo(package) AND os = $pkgInfo(os) AND cpuArch = $pkgInfo(cpuArch);}
   389    389   			}
   390    390   
   391    391   			db eval {INSERT INTO packages (hostname, sha1, package, version, os, cpuArch, isLatest, haveManifest) VALUES ($hostname, $pkgInfo(hash), $pkgInfo(package), $pkgInfo(version), $pkgInfo(os), $pkgInfo(cpuArch), $pkgInfo(isLatest), 0);}
   392         -
   393    392   		}
   394    393   
   395    394   		# Look for packages that have been deleted
   396    395   		set found_packages [db eval {SELECT sha1 FROM packages WHERE hostname = $hostname;}]
   397    396   		foreach package $found_packages {
   398    397   			set found_packages_arr($package) 1
   399    398   		}