Radish alpha
H
HardenedBSD Package Manager
Radicle
Git (anonymous pull)
Log in to clone via SSH
Real merge :)
Baptiste Daroussin committed 15 years ago
commit c885c78da7b79965af09d0b44ad29171992d5918
parent 3c9399364619f78fe08f4111bd95657ceb0a1408
1 file changed +3 -3
modified libpkg/pkg.c
@@ -202,15 +202,15 @@ pkg_open(const char *path, struct pkg **pkg_p, int query_flags)
	archive_read_support_compression_all(a);
	archive_read_support_format_tar(a);

-
	pkg_new(pkg);
-

	if (archive_read_open_filename(a, path, 4096) != ARCHIVE_OK)
		goto error;

	/* first path to check is the archive is corrupted bye the way retreive
	 * informations */

-
	(*pkg)->type = PKG_FILE;
+
	pkg_new(pkg_p);
+
	pkg = *pkg_p;
+
	pkg->type = PKG_FILE;

	array_init(&pkg->scripts, 10);
	array_init(&pkg->files, 10);