[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] emacs-25 298b2b3: * modules/mod-test/mod-test.c (Fmod_test
From: |
Eli Zaretskii |
Subject: |
[Emacs-diffs] emacs-25 298b2b3: * modules/mod-test/mod-test.c (Fmod_test_sum): Verify there are 2 args. |
Date: |
Tue, 24 Nov 2015 19:09:47 +0000 |
branch: emacs-25
commit 298b2b3f3520a6ad6dd9ae24fc8bd02a6ec9126e
Author: Philipp Stephani <address@hidden>
Commit: Eli Zaretskii <address@hidden>
* modules/mod-test/mod-test.c (Fmod_test_sum): Verify there are 2 args.
---
modules/mod-test/mod-test.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/modules/mod-test/mod-test.c b/modules/mod-test/mod-test.c
index 44a14dc..b0c535c 100644
--- a/modules/mod-test/mod-test.c
+++ b/modules/mod-test/mod-test.c
@@ -42,6 +42,8 @@ sum (intmax_t a, intmax_t b)
static emacs_value
Fmod_test_sum (emacs_env *env, ptrdiff_t nargs, emacs_value args[], void *data)
{
+ assert (nargs == 2);
+
intmax_t a = env->extract_integer (env, args[0]);
intmax_t b = env->extract_integer (env, args[1]);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] emacs-25 298b2b3: * modules/mod-test/mod-test.c (Fmod_test_sum): Verify there are 2 args.,
Eli Zaretskii <=