+#ifdef CONFIG_SELINUX
+static security_context_t current_sid;
+
+void
+renew_current_security_context(void)
+{
+ if (current_sid)
+ freecon(current_sid); /* Release old context */
+ getcon(¤t_sid); /* update */
+}
+void
+set_current_security_context(security_context_t sid)
+{
+ if (current_sid)
+ freecon(current_sid); /* Release old context */
+ current_sid = sid;
+}
+
+#endif