1
0
mirror of synced 2024-11-28 09:30:51 +01:00

fix: Building with older libyara versions

This commit is contained in:
WerWolv 2024-02-23 20:20:27 +01:00
parent 75c03d56d2
commit 2173707925

View File

@ -120,7 +120,7 @@ namespace hex::plugin::yara {
&resultContext &resultContext
); );
if (yr_compiler_add_bytes(compiler, m_content.c_str(), m_content.size(), nullptr) != ERROR_SUCCESS) { if (yr_compiler_add_string(compiler, m_content.c_str(), nullptr) != ERROR_SUCCESS) {
std::string errorMessage(0xFFFF, '\x00'); std::string errorMessage(0xFFFF, '\x00');
yr_compiler_get_error_message(compiler, errorMessage.data(), errorMessage.size()); yr_compiler_get_error_message(compiler, errorMessage.data(), errorMessage.size());