summaryrefslogtreecommitdiff
path: root/defs.h
diff options
context:
space:
mode:
authorAustin Clements <[email protected]>2012-02-17 23:20:13 -0500
committerAustin Clements <[email protected]>2012-02-17 23:20:13 -0500
commit9d59eb015141697da616a4b98ac27cf4269cd780 (patch)
tree1fc16f0aff8d60a4cf1b3c29f6b0628d3fd04f16 /defs.h
parent12abb1a56164a0d71fb7a76a465c912409f2f60b (diff)
downloadxv6-labs-9d59eb015141697da616a4b98ac27cf4269cd780.tar.gz
xv6-labs-9d59eb015141697da616a4b98ac27cf4269cd780.tar.bz2
xv6-labs-9d59eb015141697da616a4b98ac27cf4269cd780.zip
Make fetchint and fetchstr use proc instead of taking a struct proc
Previously, these were inconsistent: they used their struct proc argument for bounds checking, but always copied the argument from the current address space (and hence the current process). Drop the struct proc argument and always use the current proc. Suggested by Carmi Merimovich.
Diffstat (limited to 'defs.h')
-rw-r--r--defs.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/defs.h b/defs.h
index efbbe3d..7f1e88d 100644
--- a/defs.h
+++ b/defs.h
@@ -142,8 +142,8 @@ char* strncpy(char*, const char*, int);
int argint(int, int*);
int argptr(int, char**, int);
int argstr(int, char**);
-int fetchint(struct proc*, uint, int*);
-int fetchstr(struct proc*, uint, char**);
+int fetchint(uint, int*);
+int fetchstr(uint, char**);
void syscall(void);
// timer.c