Skip to content

Commit 0769da3

Browse files
committed
Add new error code constant; change required YARA version to 4.3
1 parent c137d3e commit 0769da3

File tree

3 files changed

+8
-4
lines changed

3 files changed

+8
-4
lines changed

README.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ the `yara-python` implementation.
1212

1313
## Build/Installation
1414

15-
On Unix-like systems, _libyara_ version 4.2, corresponding header files,
15+
On Unix-like systems, _libyara_ version 4.3, corresponding header files,
1616
and _pkg-config_ must be installed. Adding _go-yara_ v4 to a project
1717
with Go Modules enabled, simply add the proper dependency…
1818

@@ -64,7 +64,10 @@ libraries also need to be added to `CGO_LDFLAGS`.
6464

6565
## YARA 4.1.x vs. earlier versions
6666

67-
This version of _go-yara_ can only be used with YARA 4.2 or later.
67+
This version of _go-yara_ can only be used with YARA 4.3 or later.
68+
69+
Version of _go-yara_ compatible with YARA 4.1.x are available via the
70+
`v4.2.x` branch or tagged `v4.2.*` releases.
6871

6972
Version of _go-yara_ compatible with YARA 4.1.x are available via the
7073
`v4.1.x` branch or tagged `v4.1.*` releases.

cgo.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ package yara
1111
// #cgo yara_no_pkg_config LDFLAGS: -lyara -lm
1212
/*
1313
#include <yara.h>
14-
#if YR_VERSION_HEX < 0x040200
15-
#error YARA version 4.2 required
14+
#if YR_VERSION_HEX < 0x040300
15+
#error YARA version 4.3 required
1616
#endif
1717
*/
1818
import "C"

error.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,4 +91,5 @@ var errorStrings = map[int]string{
9191
C.ERROR_BLOCK_NOT_READY: "block not ready",
9292
C.ERROR_INVALID_PERCENTAGE: "invalid percentage",
9393
C.ERROR_IDENTIFIER_MATCHES_WILDCARD: "identifier matches wildcard",
94+
C.ERROR_ERROR_INVALID_VALUE: "invalid value",
9495
}

0 commit comments

Comments
 (0)