Commit Graph

3376 Commits

Author SHA1 Message Date
Juan RP
375cc30a47 Merge pull request #163 from ebfe/proplib
lib/portableproplib: fix various oob reads/segfaults
2016-04-07 16:25:46 +02:00
Michael Gehring
530149d90d lib/portableproplib: fix various oob reads/segfaults
Applies the following patches from NetBSD:

http://cvsweb.netbsd.org/bsdweb.cgi/src/common/lib/libprop/prop_object.c?rev=1.30&content-type=text/x-cvsweb-markup
http://cvsweb.netbsd.org/bsdweb.cgi/src/common/lib/libprop/prop_object_impl.h?rev=1.31.12.1&content-type=text/x-cvsweb-markup
2016-04-07 15:07:11 +02:00
Enno Boland
85f46ea295 Merge pull request #162 from ebfe/null-deref
lib/repo.c: fix potential null pointer deref
2016-04-07 06:28:48 +02:00
Michael Gehring
51511231bf lib/repo.c: fix potential null pointer deref 2016-04-07 02:15:49 +02:00
Enno Boland
ba2074a1cc xbps-rindex: use consistent output format 2016-03-31 08:10:14 +02:00
Enno Boland
aa90201b2d bin/xbps-create: remove xentry struct and clean up 2016-03-27 14:46:16 +02:00
Enno Boland
61d2361646 bin/xbps-create: process_entry_file uses dictionary instead of linked list now. 2016-03-27 14:46:13 +02:00
Enno Boland
25fa00ea46 bin/xbps-create: process dictionary instead of linked list. 2016-03-27 14:45:57 +02:00
Enno Boland
b2c7fa8846 bin/xbps-create: search for inode dublication using xbps_dictionary_t instead of linked list. 2016-03-27 14:45:41 +02:00
Enno Boland
5c18a43c1c bin/xbps-create: construct proplist objects in ftw.
This is the first commit in a series to make xbps-create build
reproducable packages.

xbps-create uses nftw(3) to walk through all files. As nftw doesn't
sort files it may happen that the resulting packages will have
different checksums due to differentiating orders of files on
different filesystems.

To solve this issue xbps-create uses xbps_directory_t, which is always
sorted, instead of a simple linked list.
2016-03-27 14:44:47 +02:00
Juan RP
35ad10ccbd Fix 29765271e correctly.
xbps_find_virtualpkg_in_conf() needs to look at the vpkgs set up in
configuration files, not from those set by pkgdb.

As a result of this the two test cases that were failing yesterday are now
fixed.
2016-03-24 10:23:20 +01:00
Enno Boland
fa635399f0 Merge pull request #156 from Gottox/atomic-rindex-a
xbps-rindex: check for consistent shlibs
2016-03-24 07:11:53 +01:00
Juan RP
29765271e9 xbps.d(5): 'virtualpkg' can now be used to map any pkg to another.
See NEWS for more information.
2016-03-23 12:46:52 +01:00
Enno Boland
855bc915e5 xbps-rindex: replace puts calls with printf 2016-03-22 09:47:25 +01:00
Enno Boland
3a067f2e20 tests: check if empty stage correctly gets removed 2016-03-22 09:47:25 +01:00
Enno Boland
2e6b2a6c94 xbps-rindex: remove empty stage file on cleanup. 2016-03-22 09:47:19 +01:00
Enno Boland
e1a76b13e5 xbps-rindex: cleanup stage area on -c too. 2016-03-21 11:39:43 +01:00
Enno Boland
b9ce711848 tests: add tests to ensure that packages in stage are not removed 2016-03-21 11:23:48 +01:00
Enno Boland
3431715d67 xbps-rindex: consider stage area when removing packages. 2016-03-21 10:50:25 +01:00
Enno Boland
008de6f470 NEWS: mention stage area 2016-03-21 08:31:18 +01:00
Enno Boland
abde080ac1 tests: add test for staged packages 2016-03-21 08:31:18 +01:00
Enno Boland
4d1ee3b01d xbps-rindex: check for consistent shlibs
When adding packages to the index, xbps-rindex will check if the
consistency of shlibs is broken by a package. If so, rindex will create
a stage file and commit the packages there. Once the consistency is restored,
rindex -a will commit the stage area back to the public repo and delete the
stage file.
2016-03-21 08:31:18 +01:00
Enno Boland
897ac238c4 Revert "xbps-rindex: check for consistent shlibs"
This reverts commit 5f4e1ad43e which was
accidently checked in in the master branch.
2016-03-20 21:40:22 +01:00
Enno Boland
5b66679929 tests: xbps-rindex add missing atf_test_case 2016-03-20 21:36:30 +01:00
Enno Boland
5f4e1ad43e xbps-rindex: check for consistent shlibs
When adding packages to the index, xbps-rindex will check if the
consistency of shlibs is broken by a package. If so, rindex will create
a stage repository and commit the packages there. Once the consistency
is restored, rindex -a will commit the stage area back to the public
repo and delete the stage file.
2016-03-20 21:36:30 +01:00
Enno Boland
45f46d02e5 Merge pull request #155 from Gottox/fix-clang
xbps-query: remove doubled incrementation
2016-03-20 17:56:38 +01:00
Enno Boland
3bcb2d6543 xbps-query: remove doubled incrementation
Otherwise clang will complain with the following message:

  search.c:67:3: error: variable 'i' is incremented both in the loop
  header and in the loop body [-Werror,-Wfor-loop-analysis]
2016-03-20 10:02:26 +01:00
Juan RP
e2693f7012 Merge pull request #151 from ebfe/freebsd
freebsd build
2016-02-08 18:42:19 +01:00
Michael Gehring
604499d6f2 contributors: fix typo 2016-02-08 15:10:07 +01:00
Michael Gehring
3bfc7b5e6d alternatives: fix dirname() buffer reuse 2016-02-08 15:10:07 +01:00
Michael Gehring
ab0d5c847d libxbps: define _WITH_GETLINE for FreeBSD 2016-02-08 15:09:58 +01:00
Michael Gehring
618e504d30 actually use HAVE_FDATASYNC 2016-02-08 15:09:43 +01:00
Michael Gehring
0f56b68eac add HAVE_STRNSTR 2016-02-08 15:09:33 +01:00
Juan RP
041708f643 Revert "Execute pkg scripts via posix_spawn(3)."
This reverts commit e33f6354c3.

@Gottox pointed out why this won't work.
2016-02-06 10:56:32 +01:00
Juan RP
9ec32ec5e3 COPYING: welcome to 2016. 2016-02-06 09:55:53 +01:00
Juan RP
0d4906e1ae xbps_xasprintf: use __attribute__(format printf) too. 2016-02-06 09:46:52 +01:00
Juan RP
2130d5daa6 proplib/prop_data: avoid 0 sized allocation reported by clang-analyzer. 2016-02-06 09:41:27 +01:00
Juan RP
c3382c5c05 Makefile: also remove temp files from 'make check'. 2016-02-06 09:31:13 +01:00
Juan RP
e526094d71 NEWS: mention recent change. 2016-02-06 09:19:51 +01:00
Juan RP
baf909caeb xbps.h: bump XBPS_APIVER due to xbps_handle::native_arch change. 2016-02-06 09:18:00 +01:00
Juan RP
a6b2954aba CONTRIBUTORS: added Michael Ghering (@ebfe). 2016-02-06 09:16:21 +01:00
Juan RP
42994ada07 Fix xbps_dbg_printf arguments by using __attribute__((format, printf)).
Patch provided by Michael Ghering in #148.

Close #148
2016-02-06 09:13:38 +01:00
Juan RP
067687ce28 libxbps: ignore updates for pkgs with held deps. Close #143 2016-02-06 09:03:54 +01:00
Juan RP
27e36fcbf9 xbps-fbulk(1): ignore xbps-src msgs (those starting with '=>').
Reported by @chneukirchen.
2016-02-05 11:44:22 +01:00
Juan RP
c91b942a45 xbps.h: increase xbps_handle::native_arch to 64.
Requested by @chneukirchen.
2016-02-05 11:43:22 +01:00
Juan RP
b759ca4b07 xbps-install(1): do not exit if pkg is up-to-date in dry-run mode.
Close #145
2016-02-05 11:27:40 +01:00
Juan RP
0fa676f50c tests/libxbps/update_hold: fix previous. 2016-02-05 11:27:07 +01:00
Juan RP
d211825a18 tests: move and rename on hold test to the correct file. 2016-02-05 11:14:18 +01:00
Juan RP
e33f6354c3 Execute pkg scripts via posix_spawn(3). 2016-02-04 11:39:02 +01:00
Juan RP
bd00a0b096 tests: comment out the cyclic_dep_full test for now. 2016-02-04 10:41:10 +01:00