remoting/host/win/wts_terminal_monitor.cc uint32_t WtsTerminalMonitor::LookupSessionId fast path and slow path has different error output
Reported by
michael_...@hotmail.com,
Oct 25 2016
|
||||
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.143 Safari/537.36 Steps to reproduce the problem: Found via static analysis What is the expected behavior? What went wrong? Possible semantic error (verification) Did this work before? N/A Chrome version: 53.0.2785.143 Channel: n/a OS Version: 10.0 Flash Version: Shockwave Flash 23.0 r0 Is there a fault handler for WTSGetActiveConsoleSessionId? (Simply returns function)
,
Nov 2 2016
,
Nov 2 2016
Specifically: // Use the fast path if the caller wants to get id of the session attached to // the physical console. if (terminal_id == kConsole) --> return WTSGetActiveConsoleSessionId(); // Enumerate all sessions and try to match the client endpoint. If this function fails, there is no fall-back to re-attempt the session in the slow-path.
,
Nov 3 2016
Zijie, can you comment on whether or not this is something we need to be concerned about (and fix it if so)?
,
Nov 3 2016
Michael, Thank you for your comment. But I do not think the logic here may introduce semantic error. According to MSDN, https://goo.gl/TVx6j4, WTSGetActiveConsoleSessionId() returns 0xFFFFFFFF if there is no console session, which is same as kInvalidSessionId. i.e. if we are searching for the console session, but there isn't one, we should eventually return kInvalidSessionId, which is 0xFFFFFFFF.
,
Nov 3 2016
|
||||
►
Sign in to add a comment |
||||
Comment 1 by kkaluri@chromium.org
, Oct 26 2016