catch unauthorized when executing rql to check an rql expression. Fix #968824
--- a/schema.py Mon May 17 17:30:52 2010 +0200
+++ b/schema.py Mon May 17 17:31:29 2010 +0200
@@ -866,6 +866,11 @@
if self.eid is not None:
session.local_perm_cache[key] = False
return False
+ except Unauthorized, ex:
+ self.debug('unauthorized %s: %s', rql, str(ex))
+ if self.eid is not None:
+ session.local_perm_cache[key] = False
+ return False
else:
rset = session.eid_rset(kwargs[keyarg])
# if no special has_*_permission relation in the rql expression, just