-
Notifications
You must be signed in to change notification settings - Fork 4
Description
Describe the bug
If the following condition is satisfied, the command line parameters are ignored.
- "Allow multiple instances" is OFF
- A Chronos instance is already running, and we launch the second or subsequent Chronos
- The command line parameters are 256 bytes or longer
- For URL-only specification: when the length is 256 bytes or more
- For URL specification plus display parameter specification: when the combined length of the two is 252 bytes or more
- Because Chronos internally combines the parameters with "|@@|", so 4 bytes are added to the parameters.
When "Allow multiple instances" is OFF, the following process sends a message to the existing instance:
https://github.com/ThinBridge/Chronos/blob/master/Sazabi.cpp#L888
In this process, GlobalAddAtom is used. However, since GlobalAddAtom only supports strings up to 255 bytes in length, if the length exceeds this limit, it results in an empty string. This is the cause of the problem.
To Reproduce
- Specify "Allow multiple instances" true
- Start Chronos
- Start a second Chronos with
Chronos.exe https://example.com/path/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa - A new tab or window is created and the URL of that is not
https://example.com/....but the default URL.
Expected behavior
https://example.com/path/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa is opened in a new tab or window
Your Environment
- Chronos version: 15.0.131.0
- ThinApps version: 2503Your Configuration
N/AYour TRACE log (Chronos_trace.log)
N/AAdditional context
No response