mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-01-06 11:39:49 -06:00
Changes name on SIMP mesage type Disconnection to InternalDisconnection (diconnection should only be used internally)
This commit is contained in:
@@ -122,7 +122,7 @@ void NetworkEngine::peerEventLoop(size_t connection_id) {
|
||||
LDEBUG(fmt::format("Connection lost to {}: {}", connection_id, err.message));
|
||||
_incomingMessages.push({
|
||||
connection_id,
|
||||
SoftwareConnection::Message{ simp::MessageType::Disconnection }
|
||||
SoftwareConnection::Message{ simp::MessageType::InternalDisconnection }
|
||||
});
|
||||
}
|
||||
break;
|
||||
@@ -222,7 +222,7 @@ void NetworkEngine::handleIncomingMessage(IncomingMessage incomingMessage) {
|
||||
_pointDataMessageHandler.handleVisibilityMessage(message, connectionPtr);
|
||||
break;
|
||||
}
|
||||
case simp::MessageType::Disconnection: {
|
||||
case simp::MessageType::InternalDisconnection: {
|
||||
LDEBUG(fmt::format("Message recieved.. Disconnect software connection: {}", incomingMessage.connection_id));
|
||||
std::lock_guard guard(_softwareConnectionsMutex);
|
||||
if (_softwareConnections.count(incomingMessage.connection_id)) {
|
||||
|
||||
@@ -335,7 +335,7 @@ SoftwareConnection::Message SoftwareConnection::receiveMessageFromSoftware() {
|
||||
auto typeEnum = softwareintegration::simp::getMessageType(type);
|
||||
|
||||
// Receive the message data
|
||||
if (typeEnum != softwareintegration::simp::MessageType::Disconnection && typeEnum != softwareintegration::simp::MessageType::Unknown) {
|
||||
if (typeEnum != softwareintegration::simp::MessageType::InternalDisconnection && typeEnum != softwareintegration::simp::MessageType::Unknown) {
|
||||
subjectBuffer.resize(subjectSize);
|
||||
if (!_socket->get(subjectBuffer.data(), subjectSize)) {
|
||||
throw SoftwareConnectionLostError("Failed to read message from socket. Disconnecting.");
|
||||
|
||||
@@ -76,7 +76,7 @@ enum class MessageType : uint32_t {
|
||||
FixedSize,
|
||||
LinearSize,
|
||||
Visibility,
|
||||
Disconnection,
|
||||
InternalDisconnection,
|
||||
Unknown
|
||||
};
|
||||
|
||||
@@ -107,7 +107,7 @@ const std::unordered_map<std::string, MessageType> _messageTypeFromSIMPType {
|
||||
{"FPSI", MessageType::FixedSize},
|
||||
{"LPSI", MessageType::LinearSize},
|
||||
{"TOVI", MessageType::Visibility},
|
||||
{"DISC", MessageType::Disconnection},
|
||||
{"DISC", MessageType::InternalDisconnection},
|
||||
};
|
||||
|
||||
const std::unordered_map<std::string, CmapNaNMode> _cmapNaNModeFromString {
|
||||
|
||||
Reference in New Issue
Block a user