Fix library name generation, fix instruction parsing.
This commit is contained in:
parent
7bca78c7a8
commit
61579bd9b7
@ -127,6 +127,10 @@ guac_client_plugin* guac_client_plugin_open(const char* protocol) {
|
|||||||
void* obj;
|
void* obj;
|
||||||
} alias;
|
} alias;
|
||||||
|
|
||||||
|
/* Add protocol and .so suffix to protocol_lib */
|
||||||
|
strcat(protocol_lib, protocol);
|
||||||
|
strcat(protocol_lib, ".so");
|
||||||
|
|
||||||
/* Load client plugin */
|
/* Load client plugin */
|
||||||
client_plugin_handle = dlopen(protocol_lib, RTLD_LAZY);
|
client_plugin_handle = dlopen(protocol_lib, RTLD_LAZY);
|
||||||
if (!client_plugin_handle) {
|
if (!client_plugin_handle) {
|
||||||
|
@ -461,8 +461,8 @@ guac_instruction* guac_protocol_read_instruction(guac_socket* socket, int usec_t
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Reset buffer */
|
/* Reset buffer */
|
||||||
memmove(socket->__instructionbuf, socket->__instructionbuf + i + 1, socket->__instructionbuf_used_length - i - 1);
|
memmove(socket->__instructionbuf, socket->__instructionbuf + i, socket->__instructionbuf_used_length - i);
|
||||||
socket->__instructionbuf_used_length -= i + 1;
|
socket->__instructionbuf_used_length -= i;
|
||||||
socket->__instructionbuf_parse_start = 0;
|
socket->__instructionbuf_parse_start = 0;
|
||||||
socket->__instructionbuf_elementc = 0;
|
socket->__instructionbuf_elementc = 0;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user