projects
/
platform
/
upstream
/
syslinux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
413a709
)
openmem: fix openmem()
syslinux-4.00-pre11
author
H. Peter Anvin
<hpa@zytor.com>
Mon, 25 Jan 2010 23:00:38 +0000
(15:00 -0800)
committer
H. Peter Anvin
<hpa@zytor.com>
Mon, 25 Jan 2010 23:00:38 +0000
(15:00 -0800)
Correct the implementation of openmem().
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
com32/lib/sys/openmem.c
patch
|
blob
|
history
diff --git
a/com32/lib/sys/openmem.c
b/com32/lib/sys/openmem.c
index
13a45c2
..
33b8de0
100644
(file)
--- a/
com32/lib/sys/openmem.c
+++ b/
com32/lib/sys/openmem.c
@@
-42,7
+42,6
@@
const struct input_dev __file_dev;
int openmem(const void *base, size_t len, int flags)
{
- com32sys_t regs;
int fd;
struct file_info *fp;
@@
-51,6
+50,8
@@
int openmem(const void *base, size_t len, int flags)
if (fd < 0)
return -1;
+ fp = &__file_info[fd];
+
fp->i.length = fp->i.nbytes = len;
fp->i.datap = (void *)base;
fp->i.filedes = 0; /* No actual file */