aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/scheduler.hxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2021-05-13 09:02:17 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2021-05-13 09:02:17 +0200
commitad9cdb9b172ecd7acf5e55b60f3f77626d72f14f (patch)
treebf26ce2bad2efdae443a03cbe7874621f4dc31cc /libbuild2/scheduler.hxx
parenta77a968800ba36cb04fb58c73e768f5ec137b45c (diff)
Do lazy allocation of shadow task queues
Diffstat (limited to 'libbuild2/scheduler.hxx')
-rw-r--r--libbuild2/scheduler.hxx3
1 files changed, 3 insertions, 0 deletions
diff --git a/libbuild2/scheduler.hxx b/libbuild2/scheduler.hxx
index b85d353..da3f0c0 100644
--- a/libbuild2/scheduler.hxx
+++ b/libbuild2/scheduler.hxx
@@ -700,6 +700,9 @@ namespace build2
// tail, if enabled. If the mark is hit, then it is disabled until the
// queue becomes empty or it is reset by a push.
//
+ // Note also that the data array can be NULL (lazy allocation) and one
+ // must make sure it's allocated before calling push().
+ //
struct task_queue_data
{
size_t head = 0;