diff options
author | Ákos Uzonyi <uzonyi.akos@gmail.com> | 2020-07-17 23:24:36 +0200 |
---|---|---|
committer | Uzonyi Ákos <uzonyi.akos@gmail.com> | 2020-07-21 11:52:55 +0200 |
commit | 03d9f49c3187a9be7b337f2cd863fa3a10ad7e7b (patch) | |
tree | 978f7207f6c08d797025bc258805e9dde8247048 | |
parent | 2ce9e7ec85182c9cee9e599acd67ce0b6cfea9de (diff) | |
download | strace-03d9f49c3187a9be7b337f2cd863fa3a10ad7e7b.tar.gz |
Remove tcb parameter of read_int_from_file
* defs.h (read_int_from_file): Remove tcb parameter.
* util.c (read_int_from_file): Likewise.
* msghdr.c (get_optmem_max): Remove tcb parameter of read_int_from_file.
-rw-r--r-- | defs.h | 2 | ||||
-rw-r--r-- | msghdr.c | 2 | ||||
-rw-r--r-- | util.c | 2 |
3 files changed, 3 insertions, 3 deletions
@@ -498,7 +498,7 @@ extern unsigned os_release; # undef KERNEL_VERSION # define KERNEL_VERSION(a, b, c) (((a) << 16) + ((b) << 8) + (c)) -extern int read_int_from_file(struct tcb *, const char *, int *); +extern int read_int_from_file(const char *, int *); extern void set_sortby(const char *); extern int set_overhead(const char *); @@ -293,7 +293,7 @@ get_optmem_max(struct tcb *tcp) static int optmem_max; if (!optmem_max) { - if (read_int_from_file(tcp, "/proc/sys/net/core/optmem_max", + if (read_int_from_file("/proc/sys/net/core/optmem_max", &optmem_max) || optmem_max <= 0) { optmem_max = sizeof(long long) * (2 * IOV_MAX + 512); } else { @@ -1517,7 +1517,7 @@ print_abnormal_hi(const kernel_ulong_t val) } int -read_int_from_file(struct tcb *tcp, const char *const fname, int *const pvalue) +read_int_from_file(const char *const fname, int *const pvalue) { const int fd = open_file(fname, O_RDONLY); if (fd < 0) |