[Bug 250439] check leftovers phase fails if @sample is a symlink with pkg 1.15.7+

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Thu Nov 19 04:44:10 UTC 2020


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=250439

--- Comment #5 from VVD <vvd at unislabs.com> ---
This diff look like source of this bug:

diff -urN pkg-1.15.8/NEWS pkg-1.15.9/NEWS
--- pkg-1.15.8/NEWS
+++ pkg-1.15.9/NEWS
@@ -1,3 +1,6 @@
+Changes from 1.15.8 to 1.15.9
+- Fix lua_pkg_copy when copying a symlink
+
 Changes from 1.15.7 to 1.15.8
 - Fix a typo making the detection of lua scripts in manifest
   unreliable in certain circumpstances
diff -urN pkg-1.15.8/auto.def pkg-1.15.9/auto.def
--- pkg-1.15.8/auto.def
+++ pkg-1.15.9/auto.def
@@ -5,7 +5,7 @@

 set maj_ver 1
 set med_ver 15
-set min_ver 8
+set min_ver 9
 set dev_ver 0
 define PKG_API [expr $maj_ver * 1000000 + $med_ver * 1000 + $min_ver]
 define VERSION $maj_ver.$med_ver.$min_ver[expr {$dev_ver ? ".$dev_ver" : ""}]
diff -urN pkg-1.15.8/libpkg/lua_scripts.c pkg-1.15.9/libpkg/lua_scripts.c
--- pkg-1.15.8/libpkg/lua_scripts.c
+++ pkg-1.15.9/libpkg/lua_scripts.c
@@ -122,7 +122,7 @@
        lua_getglobal(L, "package");
        struct pkg *pkg = lua_touserdata(L, -1);

-       if (fstatat(pkg->rootfd, RELATIVE_PATH(src), &s1, AT_SYMLINK_NOFOLLOW)
== -1) {
+       if (fstatat(pkg->rootfd, RELATIVE_PATH(src), &s1, 0) == -1) {
                lua_pushinteger(L, 2);
                return (1);
        }

Will test it now.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the freebsd-ports-bugs mailing list