]> pd.if.org Git - zpackage/blobdiff - zpm-syncfs.c
add tables to cache package library information
[zpackage] / zpm-syncfs.c
index 85c033e2789bc54d7bc0d5c9f0273378a6fcfff7..ce0c0bb85f20fa5777a092f0dec92e8731b12b0e 100644 (file)
@@ -556,7 +556,7 @@ static int read_item(struct config *conf, int ncols, char **vals, char **cols,
                }
                gr = getgrnam(val);
                if (!gr) {
-                       seterror(conf, "no group entry");
+                       seterror(conf, "no group entry for %s", val);
                        return 0;
                }
                n->gid = gr->gr_gid;
@@ -871,6 +871,12 @@ static int install_files(void *f, int ncols, char **vals, char **cols) {
                return conf->errabort;
        }
 
+#if 0
+       int64_t used, high;
+       used = sqlite3_memory_used()/1024/1024;
+       high = sqlite3_memory_highwater(0)/1024/1024;
+       fprintf(stderr, "memory = %ld MB / %ld MB\n", used, high);
+#endif
        if (conf->verbose && !conf->dryrun) {
                fprintf(stderr, "%s '%c' %s\n", nitem.opstr, nitem.ftype,
                                nitem.dest);
@@ -1302,6 +1308,7 @@ int main(int ac, char **av){
        conf.log = &localdb;
 
        if (pkgdbfile) {
+               /* TODO open read-only */
                if (!zpm_open(&pkgdb, pkgdbfile)) {
                        fprintf(stderr, "can't open src db %s\n", localdbfile);
                        exit(EXIT_FAILURE);