libselinux/libselinux-rhat.patch

41 lines
1.1 KiB
Diff
Raw Normal View History

2008-03-13 23:45:19 +00:00
diff --exclude-from=exclude -N -u -r nsalibselinux/src/label.c libselinux-2.0.59/src/label.c
--- nsalibselinux/src/label.c 2007-07-16 14:20:46.000000000 -0400
+++ libselinux-2.0.59/src/label.c 2008-03-13 19:40:24.000000000 -0400
@@ -95,7 +95,7 @@
if (compat_validate(rec, lr, "file_contexts", 0))
return NULL;
- if (translating &&
+ if (translating && (! lr->ctx_trans) &&
selinux_raw_to_trans_context(lr->ctx_raw, &lr->ctx_trans))
return NULL;
@@ -131,6 +131,7 @@
void selabel_close(struct selabel_handle *rec)
{
rec->func_close(rec);
+ free(rec->data);
free(rec);
}
diff --exclude-from=exclude -N -u -r nsalibselinux/src/matchpathcon.c libselinux-2.0.59/src/matchpathcon.c
--- nsalibselinux/src/matchpathcon.c 2007-09-28 09:48:58.000000000 -0400
2008-03-13 23:45:19 +00:00
+++ libselinux-2.0.59/src/matchpathcon.c 2008-03-13 19:23:39.000000000 -0400
2007-09-18 15:37:42 +00:00
@@ -2,6 +2,7 @@
#include <string.h>
#include <errno.h>
#include <stdio.h>
+#include <syslog.h>
#include "selinux_internal.h"
#include "label_internal.h"
#include "callbacks.h"
2007-09-18 20:44:47 +00:00
@@ -57,7 +58,7 @@
2007-09-18 15:37:42 +00:00
{
va_list ap;
va_start(ap, fmt);
- vfprintf(stderr, fmt, ap);
2007-09-18 20:44:47 +00:00
+ vsyslog(LOG_ERR, fmt, ap);
2007-09-18 15:37:42 +00:00
va_end(ap);
}