Added patch to avoid sending unexpected wakeup with uninitialized cookie value.