fix operation reply to last treated client instead to reply to sender #21
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi.
These PR fixes major problem with :server_control: capability : the server replies that the operation was made to the last client processed rather than to the sender.
This is related to this issue : https://github.com/original-male/non/issues/254
Here I only fixed the issue for main operations : new, open, save, duplicate, close, abort.
There was a weird indentation in 'abort', so I fixed it.
I also fixed the wrong reply of 'add' operation.
I could go a little further, but here it needs to take decisions.
At end of OSC_HANDLER( list) , the actual reply is wrong for sure, '/reply' or '/error' is missing.
I see 2 choices:
osc_server->send( lo_message_get_source( msg ), '/error', path, ERR_OK, "List done." );or
osc_server->send(lo_message_get_source( msg ), '/reply', '');I've got a preference for the second one, because it's not an error and a session can not have no name.
in OSC_HANDLER( quit ), do you agree that we should answer right before we shutdown the daemon?
Factually daemon should informs GUI that is quitting, it probably needs one more OSC message in GUI.