[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master d6aa50f: * src/emacs.c (read_full): Add a few assertions.
From: |
Philipp Stephani |
Subject: |
master d6aa50f: * src/emacs.c (read_full): Add a few assertions. |
Date: |
Sat, 10 Apr 2021 17:42:12 -0400 (EDT) |
branch: master
commit d6aa50f74c65c96846c774cb8f949387bf07a9ed
Author: Philipp Stephani <phst@google.com>
Commit: Philipp Stephani <phst@google.com>
* src/emacs.c (read_full): Add a few assertions.
---
src/emacs.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/emacs.c b/src/emacs.c
index 92f6bfe..9d7b21c 100644
--- a/src/emacs.c
+++ b/src/emacs.c
@@ -973,6 +973,9 @@ emacs_seccomp (unsigned int operation, unsigned int flags,
void *args)
static ptrdiff_t
read_full (int fd, void *buffer, ptrdiff_t size)
{
+ eassert (0 <= fd);
+ eassert (buffer != NULL);
+ eassert (0 <= size);
enum
{
/* See MAX_RW_COUNT in sysdep.c. */
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master d6aa50f: * src/emacs.c (read_full): Add a few assertions.,
Philipp Stephani <=