libselinux/libselinux-rhat.patch

36 lines
1.1 KiB
Diff

diff --exclude-from=exclude -N -u -r nsalibselinux/src/fgetfilecon.c libselinux-1.30.22/src/fgetfilecon.c
--- nsalibselinux/src/fgetfilecon.c 2006-07-03 07:52:49.000000000 -0400
+++ libselinux-1.30.22/src/fgetfilecon.c 2006-08-10 11:09:07.000000000 -0400
@@ -58,5 +58,8 @@
freecon(rcontext);
}
+ if (ret >= 0)
+ return strlen(*context);
+
return ret;
}
diff --exclude-from=exclude -N -u -r nsalibselinux/src/getfilecon.c libselinux-1.30.22/src/getfilecon.c
--- nsalibselinux/src/getfilecon.c 2006-07-03 07:52:49.000000000 -0400
+++ libselinux-1.30.22/src/getfilecon.c 2006-08-10 11:09:59.000000000 -0400
@@ -57,6 +57,8 @@
ret = selinux_raw_to_trans_context(rcontext, context);
freecon(rcontext);
}
+ if (ret >= 0)
+ return strlen(*context);
return ret;
}
diff --exclude-from=exclude -N -u -r nsalibselinux/src/lgetfilecon.c libselinux-1.30.22/src/lgetfilecon.c
--- nsalibselinux/src/lgetfilecon.c 2006-07-03 07:52:49.000000000 -0400
+++ libselinux-1.30.22/src/lgetfilecon.c 2006-08-10 11:06:59.000000000 -0400
@@ -58,5 +58,7 @@
freecon(rcontext);
}
+ if (ret >= 0)
+ return strlen(*context);
return ret;
}