- Fix patch call
This commit is contained in:
parent
b86cfc3a43
commit
fedf8202cb
@ -16,7 +16,7 @@ diff --exclude-from=exclude -N -u -r nsalibselinux/include/selinux/selinux.h lib
|
|||||||
configuration files exist.
|
configuration files exist.
|
||||||
diff --exclude-from=exclude -N -u -r nsalibselinux/src/matchpathcon.c libselinux-1.26/src/matchpathcon.c
|
diff --exclude-from=exclude -N -u -r nsalibselinux/src/matchpathcon.c libselinux-1.26/src/matchpathcon.c
|
||||||
--- nsalibselinux/src/matchpathcon.c 2005-08-24 09:07:11.000000000 -0400
|
--- nsalibselinux/src/matchpathcon.c 2005-08-24 09:07:11.000000000 -0400
|
||||||
+++ libselinux-1.26/src/matchpathcon.c 2005-09-16 14:21:02.000000000 -0400
|
+++ libselinux-1.26/src/matchpathcon.c 2005-09-16 15:54:01.000000000 -0400
|
||||||
@@ -12,6 +12,7 @@
|
@@ -12,6 +12,7 @@
|
||||||
#include <regex.h>
|
#include <regex.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
@ -25,7 +25,7 @@ diff --exclude-from=exclude -N -u -r nsalibselinux/src/matchpathcon.c libselinux
|
|||||||
|
|
||||||
static void
|
static void
|
||||||
#ifdef __GNUC__
|
#ifdef __GNUC__
|
||||||
@@ -25,6 +26,17 @@
|
@@ -25,6 +26,19 @@
|
||||||
va_end(ap);
|
va_end(ap);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -33,17 +33,19 @@ diff --exclude-from=exclude -N -u -r nsalibselinux/src/matchpathcon.c libselinux
|
|||||||
+ if (! mls_enabled) { \
|
+ if (! mls_enabled) { \
|
||||||
+ security_context_t newcon; \
|
+ security_context_t newcon; \
|
||||||
+ context_t con=context_new(CON); \
|
+ context_t con=context_new(CON); \
|
||||||
|
+ if (con) { \
|
||||||
+ context_range_set(con,NULL); \
|
+ context_range_set(con,NULL); \
|
||||||
+ newcon=strdup(context_str(con));\
|
+ newcon=strdup(context_str(con));\
|
||||||
+ context_free(con); \
|
+ context_free(con); \
|
||||||
+ freecon(CON); \
|
+ freecon(CON); \
|
||||||
+ CON=newcon; \
|
+ CON=newcon; \
|
||||||
|
+ } \
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
static void (*myprintf)(const char *fmt, ...) = &default_printf;
|
static void (*myprintf)(const char *fmt, ...) = &default_printf;
|
||||||
|
|
||||||
void set_matchpathcon_printf(void (*f)(const char *fmt, ...))
|
void set_matchpathcon_printf(void (*f)(const char *fmt, ...))
|
||||||
@@ -415,7 +427,7 @@
|
@@ -415,7 +429,7 @@
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -52,7 +54,7 @@ diff --exclude-from=exclude -N -u -r nsalibselinux/src/matchpathcon.c libselinux
|
|||||||
int items, len, regerr;
|
int items, len, regerr;
|
||||||
char *buf_p;
|
char *buf_p;
|
||||||
char *regex, *type, *context;
|
char *regex, *type, *context;
|
||||||
@@ -438,6 +450,7 @@
|
@@ -438,6 +452,7 @@
|
||||||
} else if (items == 2) {
|
} else if (items == 2) {
|
||||||
/* The type field is optional. */
|
/* The type field is optional. */
|
||||||
free(context);
|
free(context);
|
||||||
@ -60,7 +62,7 @@ diff --exclude-from=exclude -N -u -r nsalibselinux/src/matchpathcon.c libselinux
|
|||||||
context = type;
|
context = type;
|
||||||
type = 0;
|
type = 0;
|
||||||
}
|
}
|
||||||
@@ -510,7 +523,7 @@
|
@@ -510,7 +525,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
skip_type:
|
skip_type:
|
||||||
@ -69,7 +71,7 @@ diff --exclude-from=exclude -N -u -r nsalibselinux/src/matchpathcon.c libselinux
|
|||||||
spec_arr[nspec].context = context;
|
spec_arr[nspec].context = context;
|
||||||
|
|
||||||
if (strcmp(context, "<<none>>")) {
|
if (strcmp(context, "<<none>>")) {
|
||||||
@@ -557,6 +570,7 @@
|
@@ -557,6 +572,7 @@
|
||||||
unsigned int lineno, pass, i, j, maxnspec;
|
unsigned int lineno, pass, i, j, maxnspec;
|
||||||
spec_t *spec_copy=NULL;
|
spec_t *spec_copy=NULL;
|
||||||
int status=-1;
|
int status=-1;
|
||||||
@ -77,7 +79,7 @@ diff --exclude-from=exclude -N -u -r nsalibselinux/src/matchpathcon.c libselinux
|
|||||||
|
|
||||||
/* Open the specification file. */
|
/* Open the specification file. */
|
||||||
if (!path)
|
if (!path)
|
||||||
@@ -590,20 +604,20 @@
|
@@ -590,20 +606,20 @@
|
||||||
lineno = 0;
|
lineno = 0;
|
||||||
nspec = 0;
|
nspec = 0;
|
||||||
while (getline(&line_buf, &line_len, fp) > 0 && nspec < maxnspec) {
|
while (getline(&line_buf, &line_len, fp) > 0 && nspec < maxnspec) {
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
Summary: SELinux library and simple utilities
|
Summary: SELinux library and simple utilities
|
||||||
Name: libselinux
|
Name: libselinux
|
||||||
Version: 1.26
|
Version: 1.26
|
||||||
Release: 5
|
Release: 6
|
||||||
License: Public domain (uncopyrighted)
|
License: Public domain (uncopyrighted)
|
||||||
Group: System Environment/Libraries
|
Group: System Environment/Libraries
|
||||||
Source: http://www.nsa.gov/selinux/archives/%{name}-%{version}.tgz
|
Source: http://www.nsa.gov/selinux/archives/%{name}-%{version}.tgz
|
||||||
@ -86,6 +86,9 @@ rm -rf ${RPM_BUILD_ROOT}
|
|||||||
%{_mandir}/man8/*
|
%{_mandir}/man8/*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Sep 12 2005 Dan Walsh <dwalsh@redhat.com> 1.26-6
|
||||||
|
- Fix patch call
|
||||||
|
|
||||||
* Tue Sep 12 2005 Dan Walsh <dwalsh@redhat.com> 1.26-5
|
* Tue Sep 12 2005 Dan Walsh <dwalsh@redhat.com> 1.26-5
|
||||||
- Fix strip_con call
|
- Fix strip_con call
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user