diff options
author | Cristian Cadar <c.cadar@imperial.ac.uk> | 2016-05-27 18:43:04 +0100 |
---|---|---|
committer | Cristian Cadar <c.cadar@imperial.ac.uk> | 2016-05-27 18:43:04 +0100 |
commit | d91432084ddb54ed528ae059c114cc5b225241c2 (patch) | |
tree | 73de3ff50dbc4b2f9e102f3c17316484ebca49a5 /runtime/POSIX/fd_init.c | |
parent | a8012548f2cc31e2c2283f9f500b281532aa5aa7 (diff) | |
parent | 71a7e31ed99625e2f493ad99972b8446744da54e (diff) | |
download | klee-d91432084ddb54ed528ae059c114cc5b225241c2.tar.gz |
Merge pull request #397 from andreamattavelli/refactoring_stdin
Distinct options for symbolic files and symbolic stdin
Diffstat (limited to 'runtime/POSIX/fd_init.c')
-rw-r--r-- | runtime/POSIX/fd_init.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/runtime/POSIX/fd_init.c b/runtime/POSIX/fd_init.c index 8b69fd04..9184b7ea 100644 --- a/runtime/POSIX/fd_init.c +++ b/runtime/POSIX/fd_init.c @@ -107,9 +107,9 @@ static unsigned __sym_uint32(const char *name) { writes past the initial file size are discarded (file offset is always incremented) max_failures: maximum number of system call failures */ -void klee_init_fds(unsigned n_files, unsigned file_length, - int sym_stdout_flag, int save_all_writes_flag, - unsigned max_failures) { +void klee_init_fds(unsigned n_files, unsigned file_length, + unsigned stdin_length, int sym_stdout_flag, + int save_all_writes_flag, unsigned max_failures) { unsigned k; char name[7] = "?-data"; struct stat64 s; @@ -124,9 +124,9 @@ void klee_init_fds(unsigned n_files, unsigned file_length, } /* setting symbolic stdin */ - if (file_length) { + if (stdin_length) { __exe_fs.sym_stdin = malloc(sizeof(*__exe_fs.sym_stdin)); - __create_new_dfile(__exe_fs.sym_stdin, file_length, "stdin", &s); + __create_new_dfile(__exe_fs.sym_stdin, stdin_length, "stdin", &s); __exe_env.fds[0].dfile = __exe_fs.sym_stdin; } else __exe_fs.sym_stdin = NULL; |