Diff

Differences From Artifact [bfe8021807]:

To Artifact [99393ab276]:


   278    278   			}
   279    279   
   280    280   			if {$pkgInfo(isLatest)} {
   281    281   				db eval {UPDATE packages SET isLatest = 0 WHERE hostname = $hostname AND package = $pkgInfo($package) AND os = $pkgInfo($package) AND cpuArch = $pkgInfo(cpuArch);}
   282    282   			}
   283    283   
   284    284   			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);}
          285  +
   285    286   		}
   286    287   
   287    288   		# Look for packages that have been deleted
   288    289   		set found_packages [db eval {SELECT sha1 FROM packages WHERE hostname = $hostname;}]
   289    290   		foreach package $found_packages {
   290    291   			set found_packages_arr($package) 1
   291    292   		}
................................................................................
   295    296   		}
   296    297   
   297    298   		foreach package [array names found_packages_arr] {
   298    299   			db eval {DELETE FROM packages WHERE hostname = $hostname AND sha1 = $package;}
   299    300   		}
   300    301   
   301    302   		db eval {INSERT OR REPLACE INTO sites (hostname, lastUpdate, ttl) VALUES ($hostname, $now, $::appfs::ttl);}
          303  +
          304  +		appfsd::get_path_info_cache_flush
   302    305   
   303    306   		return COMPLETE
   304    307   	}
   305    308   
   306    309   	proc getpkgmanifest {hostname package_sha1} {
   307    310   		set haveManifests [db eval {SELECT haveManifest FROM packages WHERE sha1 = $package_sha1 LIMIT 1;}]
   308    311   		set haveManifest [lindex $haveManifests 0]
................................................................................
   354    357   				set fileInfo(directory) [join [lrange $fileInfo(name) 0 end-1] "/"]
   355    358   				set fileInfo(name) [lindex $fileInfo(name) end]
   356    359   
   357    360   				db eval {INSERT INTO files (package_sha1, type, time, source, size, perms, file_sha1, file_name, file_directory) VALUES ($package_sha1, $fileInfo(type), $fileInfo(time), $fileInfo(source), $fileInfo(size), $fileInfo(perms), $fileInfo(sha1), $fileInfo(name), $fileInfo(directory) );}
   358    361   				db eval {UPDATE packages SET haveManifest = 1 WHERE sha1 = $package_sha1;}
   359    362   			}
   360    363   		}
          364  +
          365  +		appfsd::get_path_info_cache_flush
   361    366   
   362    367   		return COMPLETE
   363    368   	}
   364    369   
   365    370   	proc _localpath {package hostname file} {
   366    371   		set dir ""
   367    372   		catch {