Radish alpha
H
rad:z3QDZAW2FAfuLvihrhiyDC9fAD8G9
HardenedBSD Package Manager
Radicle
Git
Use pkg_load_manifest_file in pkg_create
Baptiste Daroussin committed 14 years ago
commit 85e0b95f88361e5f56bf655b27afc0267128c9cd
parent edc1cbe
1 file changed +1 -6
modified libpkg/pkg_create.c
@@ -120,7 +120,6 @@ pkg_create_fakeroot(const char *outdir, pkg_formats format, const char *rootdir,
	struct packing *pkg_archive = NULL;
	char *manifest = NULL, *manifest_path = NULL;
	int ret = ENOMEM;
-
	off_t sz;

	/* Load the manifest from the metadata directory */
	if (asprintf(&manifest_path, "%s/+MANIFEST", metadatadir) == -1)
@@ -130,11 +129,7 @@ pkg_create_fakeroot(const char *outdir, pkg_formats format, const char *rootdir,
	if (pkg == NULL)
		goto cleanup;

-
	ret = file_to_buffer(manifest_path, &manifest, &sz);
-
	if (ret != EPKG_OK)
-
		goto cleanup;
-

-
	ret = pkg_parse_manifest(pkg, manifest);
+
	ret = pkg_load_manifest_file(pkg, manifest_path);

	/* Create the archive */
	pkg_archive = pkg_create_archive(outdir, pkg, format, 0);