[Forensics-changes] [yara] 63/135: Add first_memory_block macro
Hilko Bengen
bengen at moszumanska.debian.org
Sat Jul 1 10:27:32 UTC 2017
This is an automated email from the git hooks/post-receive script.
bengen pushed a commit to annotated tag v3.1.0
in repository yara.
commit 912bb62221f7e04a43df79c40bc54942678dbe4c
Author: Victor M. Alvarez <plusvic at gmail.com>
Date: Thu Jul 17 13:56:02 2014 +0200
Add first_memory_block macro
---
libyara/include/yara/modules.h | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/libyara/include/yara/modules.h b/libyara/include/yara/modules.h
index 25c9494..2e6a128 100644
--- a/libyara/include/yara/modules.h
+++ b/libyara/include/yara/modules.h
@@ -169,11 +169,15 @@ limitations under the License.
#define foreach_memory_block(context, block) \
- for (block = context->mem_block; \
+ for (block = (context)->mem_block; \
block != NULL; \
block = block->next) \
+#define first_memory_block(context) \
+ (context)->mem_block
+
+
#define get_object(object, ...) \
yr_object_lookup(object, 0, __VA_ARGS__)
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/forensics/yara.git
More information about the forensics-changes
mailing list