Smallers steps to keep plugin running
[oweals/gnunet.git] / src / include / gnunet_scheduler_lib.h
index 3205729a3ff82ebbdcb9c9bba6aede10988d6334..b39feb9268b108aadc1a223270912eddc7d0889b 100644 (file)
@@ -141,11 +141,21 @@ enum GNUNET_SCHEDULER_Priority
    */
   GNUNET_SCHEDULER_PRIORITY_URGENT = 6,
 
+  /**
+   * This is an internal priority level that is only used for tasks
+   * that are being triggered due to shutdown (they have automatically
+   * highest priority).  User code must not use this priority level
+   * directly.  Tasks run with this priority level that internally
+   * schedule other tasks will see their original priority level
+   * be inherited (unless otherwise specified).
+   */
+  GNUNET_SCHEDULER_PRIORITY_SHUTDOWN = 7,
+
   /**
    * Number of priorities (must be the last priority).
    * This priority must not be used by clients.
    */
-  GNUNET_SCHEDULER_PRIORITY_COUNT = 7
+  GNUNET_SCHEDULER_PRIORITY_COUNT = 8
 };
 
 #include "gnunet_time_lib.h"
@@ -473,7 +483,7 @@ GNUNET_SCHEDULER_add_write_file (struct GNUNET_SCHEDULER_Handle *sched,
  * && (delay-ready
  *     || any-rs-ready
  *     || any-ws-ready
- *     || (shutdown-active && run-on-shutdown) )
+ *     || shutdown-active)
  * </code>
  *
  * @param sched scheduler to use