context: Fixed issue where queue would never flush if maxlen was None

Signed-off-by: Joe MacMahon <joe.macmahon@cern.ch>