Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Matthieu Dorier
codes
Commits
d27bfda1
Commit
d27bfda1
authored
May 28, 2014
by
Philip Carns
Browse files
bugfix: terminate strings read from file
parent
44a80528
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/iokernellang/CodesKernelHelpers.c
View file @
d27bfda1
...
...
@@ -333,7 +333,8 @@ int codes_kernel_helper_bootstrap(char * io_kernel_path, char *
ksize
=
info
.
st_size
;
/* allocate a buffer for the kernel */
kbuffer
=
(
char
*
)
malloc
(
sizeof
(
char
)
*
ksize
);
kbuffer
=
(
char
*
)
malloc
(
sizeof
(
char
)
*
(
ksize
+
1
));
kbuffer
[
ksize
]
=
'\0'
;
/* get data from the kernel file */
fd
=
open
(
io_kernel_path
,
O_RDONLY
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment