src/filed/job.c
static bool access_ok(struct s_cmds *cmd, DIRRES* dir)
{
   if ((cmd->access & ACCESS_MONITOR) && dir->monitor) {
      return true;
   }
   if ((cmd->access & ACCESS_REMOTE) && dir->remote) {
      return true;
   }
   if (!dir->remote && !dir->monitor) {
      return true;
   }
   return false;
}
/* Should tell us if a command is authorized or not */
Should tell us if a command is authorized or not
Should tell us if a command is authorized or not
static bool access_ok(struct s_cmds *cmd, DIRRES* dir)
{
   if ((cmd->access & ACCESS_MONITOR) && dir->monitor) {
      return true;
   }
   if ((cmd->access & ACCESS_REMOTE) && dir->remote) {
      return true;
   }
   if (!dir->remote && !dir->monitor) {
      return true;
   }
   return false;
}
static bool access_ok ( struct s_cmds * cmd , DIRRES * dir ) { if ( ( cmd -> access & ACCESS_MONITOR ) && dir -> monitor ) { return true ; } if ( ( cmd -> access & ACCESS_REMOTE ) && dir -> remote ) { return true ; } if ( ! dir -> remote && ! dir -> monitor ) { return true ; } return false ; }
Should tell us if a command is authorized or not
Should tell us if a command is authorized or not