diff options
| -rw-r--r-- | binaryninjaapi.h | 2 | ||||
| -rw-r--r-- | binaryninjacore.h | 2 | ||||
| -rw-r--r-- | collaboration.cpp | 12 |
3 files changed, 10 insertions, 6 deletions
diff --git a/binaryninjaapi.h b/binaryninjaapi.h index 1dd3bc0f..6cd7eaf2 100644 --- a/binaryninjaapi.h +++ b/binaryninjaapi.h @@ -22532,7 +22532,7 @@ namespace BinaryNinja::Collaboration std::string GetUsername(); std::string GetToken(); int GetServerVersion(); - std::string GetServerBuildVersion(); + VersionInfo GetServerBuildVersion(); std::string GetServerBuildId(); std::vector<std::pair<std::string, std::string>> GetAuthBackends(); bool HasPulledProjects(); diff --git a/binaryninjacore.h b/binaryninjacore.h index f28f3c42..b3c3e8e0 100644 --- a/binaryninjacore.h +++ b/binaryninjacore.h @@ -8582,7 +8582,7 @@ extern "C" BINARYNINJACOREAPI char* BNRemoteGetUsername(BNRemote* remote); BINARYNINJACOREAPI char* BNRemoteGetToken(BNRemote* remote); BINARYNINJACOREAPI int BNRemoteGetServerVersion(BNRemote* remote); - BINARYNINJACOREAPI char* BNRemoteGetServerBuildVersion(BNRemote* remote); + BINARYNINJACOREAPI BNVersionInfo BNRemoteGetServerBuildVersion(BNRemote* remote); BINARYNINJACOREAPI char* BNRemoteGetServerBuildId(BNRemote* remote); BINARYNINJACOREAPI bool BNRemoteGetAuthBackends(BNRemote* remote, char*** backendIds, char*** backendNames, size_t* count); BINARYNINJACOREAPI bool BNRemoteHasPulledProjects(BNRemote* remote); diff --git a/collaboration.cpp b/collaboration.cpp index 15000cda..19a7168b 100644 --- a/collaboration.cpp +++ b/collaboration.cpp @@ -632,11 +632,15 @@ int Remote::GetServerVersion() } -std::string Remote::GetServerBuildVersion() +VersionInfo Remote::GetServerBuildVersion() { - char* buildVersion = BNRemoteGetServerBuildVersion(m_object); - std::string result = buildVersion; - BNFreeString(buildVersion); + BNVersionInfo bnVersion = BNRemoteGetServerBuildVersion(m_object); + VersionInfo result; + result.major = bnVersion.major; + result.minor = bnVersion.minor; + result.build = bnVersion.build; + result.channel = bnVersion.channel; + BNFreeString(bnVersion.channel); return result; } |
