Radish alpha
H
rad:z3QDZAW2FAfuLvihrhiyDC9fAD8G9
HardenedBSD Package Manager
Radicle
Git
reproducibility: fix regression in DL_SORT
Baptiste Daroussin committed 2 months ago
commit 544d62cdb498dfe917c4e3731b52ff654f1621cf
parent 9c40fc5
3 files changed +14 -14
modified libpkg/pkg.c
@@ -2029,31 +2029,31 @@ pkg_message_to_str(struct pkg *pkg)
static int
pkg_dep_cmp(struct pkg_dep *a, struct pkg_dep *b)
{
-
	return (STREQ(a->name, b->name));
+
	return (strcmp(a->name, b->name));
}

static int
pkg_file_cmp(struct pkg_file *a, struct pkg_file *b)
{
-
	return (STREQ(a->path, b->path));
+
	return (strcmp(a->path, b->path));
}

static int
pkg_dir_cmp(struct pkg_dir *a, struct pkg_dir *b)
{
-
	return (STREQ(a->path, b->path));
+
	return (strcmp(a->path, b->path));
}

static int
pkg_option_cmp(struct pkg_option *a, struct pkg_option *b)
{
-
	return (STREQ(a->key, b->key));
+
	return (strcmp(a->key, b->key));
}

static int
pkg_cf_cmp(struct pkg_config_file *a, struct pkg_config_file *b)
{
-
	return (STREQ(a->path, b->path));
+
	return (strcmp(a->path, b->path));
}

void
modified tests/frontend/create.sh
@@ -561,22 +561,22 @@ categories [
    "test",
]
files {
-
    /testfile {
-
        sum = "1\$e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855";
+
    /sym-file {
+
        sum = "1\$a83552cc4e1e92707178239c630b7f05d51124ff2afa7c5595ff4e76cb96cfa4";
        uname = "root";
        gname = "wheel";
        perm = "0644";
        fflags = 0;
-
        mtime = ${test_file_mtime};
+
        symlink_target = "sym-target";
+
        mtime = ${sym_file_mtime};
    }
-
    /sym-file {
-
        sum = "1\$a83552cc4e1e92707178239c630b7f05d51124ff2afa7c5595ff4e76cb96cfa4";
+
    /testfile {
+
        sum = "1\$e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855";
        uname = "root";
        gname = "wheel";
        perm = "0644";
        fflags = 0;
-
        symlink_target = "sym-target";
-
        mtime = ${sym_file_mtime};
+
        mtime = ${test_file_mtime};
    }
}
EOF
@@ -760,7 +760,7 @@ EOF
		-s exit:0 \
		pkg create -o ${TMPDIR} -m . -p test.plist -r .

-
	atf_check -o inline:"/file1\n/file3\n/file2\n" pkg info -ql -F test*.pkg
+
	atf_check -o inline:"/file1\n/file2\n/file3\n" pkg info -ql -F test*.pkg
	cat << EOF >> other-plist
@include test.plist
EOF
modified tests/frontend/query.sh
@@ -251,7 +251,7 @@ EOF
		pkg create -M plop.ucl

	atf_check \
-
		-o inline:"${TMPDIR}/plop\n${TMPDIR}/bla\n${TMPDIR}/sym\n" \
+
		-o inline:"${TMPDIR}/bla\n${TMPDIR}/plop\n${TMPDIR}/sym\n" \
		-e empty \
		-s exit:0 \
		pkg query -F ./test-1.pkg '%Fp'