rpms/libsemanage/devel libsemanage-rhat.patch, 1.17, 1.18 libsemanage.spec, 1.113, 1.114

fedora-cvs-commits at redhat.com fedora-cvs-commits at redhat.com
Fri Dec 22 16:50:52 UTC 2006


Author: dwalsh

Update of /cvs/dist/rpms/libsemanage/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv2073

Modified Files:
	libsemanage-rhat.patch libsemanage.spec 
Log Message:
* Fri Dec 22 2006 Dan Walsh <dwalsh at redhat.com> - 1.9.1-3
- Apply Karl MacMillan patch to get proper error codes.


libsemanage-rhat.patch:
 direct_api.c |   28 ++++++++++++++++++----------
 1 files changed, 18 insertions(+), 10 deletions(-)

Index: libsemanage-rhat.patch
===================================================================
RCS file: /cvs/dist/rpms/libsemanage/devel/libsemanage-rhat.patch,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -r1.17 -r1.18
--- libsemanage-rhat.patch	29 Sep 2006 14:43:48 -0000	1.17
+++ libsemanage-rhat.patch	22 Dec 2006 16:50:50 -0000	1.18
@@ -1,13 +1,70 @@
---- libsemanage-1.6.16/src/semanage_store.c~	2006-08-23 13:57:48.000000000 -0400
-+++ libsemanage-1.6.16/src/semanage_store.c	2006-09-29 10:41:08.000000000 -0400
-@@ -1106,6 +1106,10 @@
- 			goto skip_reload;
- 		}
+diff --exclude-from=exclude -N -u -r nsalibsemanage/src/direct_api.c libsemanage-1.9.1/src/direct_api.c
+--- nsalibsemanage/src/direct_api.c	2006-11-16 17:14:02.000000000 -0500
++++ libsemanage-1.9.1/src/direct_api.c	2006-12-22 11:36:55.000000000 -0500
+@@ -603,7 +603,8 @@
+ 
+ 		/* Create new policy object, then attach to policy databases
+ 		 * that work with a policydb */
+-		if (semanage_expand_sandbox(sh, base, &out) < 0)
++		retval = semanage_expand_sandbox(sh, base, &out);
++		if (retval < 0)
+ 			goto cleanup;
+ 
+ 		dbase_policydb_attach((dbase_policydb_t *) pusers_base->dbase,
+@@ -615,13 +616,16 @@
+ 
+ 		/* ============= Apply changes, and verify  =============== */
+ 
+-		if (semanage_base_merge_components(sh) < 0)
++		retval = semanage_base_merge_components(sh);
++		if (retval < 0)
+ 			goto cleanup;
+-
+-		if (semanage_write_policydb(sh, out) < 0)
++ 
++		retval = semanage_write_policydb(sh, out);
++		if (retval < 0)
+ 			goto cleanup;
+-
+-		if (semanage_verify_kernel(sh) != 0)
++ 
++		retval = semanage_verify_kernel(sh);
++		if (retval < 0)
+ 			goto cleanup;
+ 	}
+ 
+@@ -635,26 +639,30 @@
+ 	 * merged into the main file_contexts. We won't check the 
+ 	 * large file_contexts - checked at compile time */
+ 	if (sh->do_rebuild || modified || fcontexts_modified) {
+-		if (semanage_fcontext_validate_local(sh, out) < 0)
++		retval = semanage_fcontext_validate_local(sh, out);
++		if (retval < 0)
+ 			goto cleanup;
  	}
-+	else 
-+		if (errno == ENOENT && 
-+		    strcmp(really_active_store, storepath) != 0)
-+			goto skip_reload;
  
- 	if (semanage_reload_policy(sh)) {
+ 	/* Validate local seusers against policy */
+ 	if (sh->do_rebuild || modified || seusers_modified) {
+-		if (semanage_seuser_validate_local(sh, out) < 0)
++		retval = semanage_seuser_validate_local(sh, out);
++		if (retval < 0)
+ 			goto cleanup;
+ 	}
+ 
+ 	/* Validate local ports for overlap */
+ 	if (sh->do_rebuild || ports_modified) {
+-		if (semanage_port_validate_local(sh) < 0)
++		retval = semanage_port_validate_local(sh);
++		if (retval < 0)
+ 			goto cleanup;
+ 	}
+ 
+ 	/* ================== Write non-policydb components ========= */
+ 
+ 	/* Commit changes to components */
+-	if (semanage_commit_components(sh) < 0)
++	retval = semanage_commit_components(sh);
++	if (retval < 0)
  		goto cleanup;
+ 
+ 	retval = semanage_install_sandbox(sh);


Index: libsemanage.spec
===================================================================
RCS file: /cvs/dist/rpms/libsemanage/devel/libsemanage.spec,v
retrieving revision 1.113
retrieving revision 1.114
diff -u -r1.113 -r1.114
--- libsemanage.spec	7 Dec 2006 16:39:43 -0000	1.113
+++ libsemanage.spec	22 Dec 2006 16:50:50 -0000	1.114
@@ -3,10 +3,11 @@
 Summary: SELinux binary policy manipulation library 
 Name: libsemanage
 Version: 1.9.1
-Release: 2
+Release: 3%{?dist}
 License: GPL
 Group: System Environment/Libraries
 Source: http://www.nsa.gov/selinux/archives/libsemanage-%{version}.tgz
+Patch: libsemanage-rhat.patch
 
 BuildRoot: %{_tmppath}/%{name}-buildroot
 BuildRequires: libselinux-devel >= %{libselinuxver} swig
@@ -40,6 +41,7 @@
 
 %prep
 %setup -q
+%patch -p1 -b .rhat
 
 %build
 make clean
@@ -75,6 +77,9 @@
 %{_mandir}/man3/*
 
 %changelog
+* Fri Dec 22 2006 Dan Walsh <dwalsh at redhat.com> - 1.9.1-3
+- Apply Karl MacMillan patch to get proper error codes.
+
 * Thu Dec  7 2006 Jeremy Katz <katzj at redhat.com> - 1.9.1-2
 - rebuild against python 2.5
 




More information about the fedora-cvs-commits mailing list