projects
/
cvc5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e313adf
)
Closing an open file descriptor in MemoryMapFile.
author
Tim King
<taking@google.com>
Mon, 26 Sep 2016 04:03:39 +0000
(21:03 -0700)
committer
Tim King
<taking@google.com>
Mon, 26 Sep 2016 04:03:39 +0000
(21:03 -0700)
src/parser/memory_mapped_input_buffer.cpp
patch
|
blob
|
history
diff --git
a/src/parser/memory_mapped_input_buffer.cpp
b/src/parser/memory_mapped_input_buffer.cpp
index c9515aa92c33a9a39882920669916da87cd51fed..1554428f7288a822fa6ff28e32e3a5b67f499793 100644
(file)
--- a/
src/parser/memory_mapped_input_buffer.cpp
+++ b/
src/parser/memory_mapped_input_buffer.cpp
@@
-110,6
+110,7
@@
static ANTLR3_UINT32 MemoryMapFile(pANTLR3_INPUT_STREAM input,
input->data = mmap(0, input->sizeBuf, PROT_READ, MAP_PRIVATE, fd, 0);
errno = 0;
+ close(fd);
if(intptr_t(input->data) == -1) {
return ANTLR3_ERR_NOMEM;
}