git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
This commit was manufactured by cvs2svn to create tag
[linux-2.6.git]
/
drivers
/
isdn
/
hysdn
/
hysdn_procconf.c
diff --git
a/drivers/isdn/hysdn/hysdn_procconf.c
b/drivers/isdn/hysdn/hysdn_procconf.c
index
5da507e
..
2a312de
100644
(file)
--- a/
drivers/isdn/hysdn/hysdn_procconf.c
+++ b/
drivers/isdn/hysdn/hysdn_procconf.c
@@
-89,12
+89,14
@@
process_line(struct conf_writedata *cnf)
/* write conf file -> boot or send cfg line to card */
/****************************************************/
static ssize_t
/* write conf file -> boot or send cfg line to card */
/****************************************************/
static ssize_t
-hysdn_conf_write(struct file *file, const char
__user
*buf, size_t count, loff_t * off)
+hysdn_conf_write(struct file *file, const char *buf, size_t count, loff_t * off)
{
struct conf_writedata *cnf;
int i;
uchar ch, *cp;
{
struct conf_writedata *cnf;
int i;
uchar ch, *cp;
+ if (&file->f_pos != off) /* fs error check */
+ return (-ESPIPE);
if (!count)
return (0); /* nothing to handle */
if (!count)
return (0); /* nothing to handle */
@@
-207,11
+209,14
@@
hysdn_conf_write(struct file *file, const char __user *buf, size_t count, loff_t
/* read conf file -> output card info data */
/*******************************************/
static ssize_t
/* read conf file -> output card info data */
/*******************************************/
static ssize_t
-hysdn_conf_read(struct file *file, char
__user
*buf, size_t count, loff_t * off)
+hysdn_conf_read(struct file *file, char *buf, size_t count, loff_t * off)
{
char *cp;
int i;
{
char *cp;
int i;
+ if (off != &file->f_pos) /* fs error check */
+ return -ESPIPE;
+
if (file->f_mode & FMODE_READ) {
if (!(cp = file->private_data))
return (-EFAULT); /* should never happen */
if (file->f_mode & FMODE_READ) {
if (!(cp = file->private_data))
return (-EFAULT); /* should never happen */
@@
-315,7
+320,7
@@
hysdn_conf_open(struct inode *ino, struct file *filep)
return (-EPERM); /* no permission this time */
}
unlock_kernel();
return (-EPERM); /* no permission this time */
}
unlock_kernel();
- return
nonseekable_open(ino, filep
);
+ return
(0
);
} /* hysdn_conf_open */
/***************************/
} /* hysdn_conf_open */
/***************************/