Skip to contentSkip to conversation

tty: PTR_ERR return of wrong pointer in fs3270_open()

PATCH In review Roel Kluin 2 participants 2 messages Dec 7, 2009 s390

lore
Share & tools
lore

Roel Kluin

author
#0 lore raw

PATCH 1/1 tty: PTR_ERR return of wrong pointer in fs3270_open()

Return the PTR_ERR of the correct pointer.

---
 drivers/s390/char/fs3270.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/s390/char/fs3270.c +1 -1
index 097d384..2ae58d0 100644
@@ -465,7 +465,7 @@ fs3270_open(struct inode *inode, struct file *filp)
 	if (IS_ERR(ib)) {
 		raw3270_put_view(&fp->view);
 		raw3270_del_view(&fp->view);
-		rc = PTR_ERR(fp);
+		rc = PTR_ERR(ib);
 		goto out;
 	}
 	fp->rdbuf = ib;
#1 lore raw
Quoted 12 lines · On Mon, 07 Dec 2009 14:33:39 +0100 Roel Kluin <[email protected]> wrote:

Return the PTR_ERR of the correct pointer.

---
 drivers/s390/char/fs3270.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/s390/char/fs3270.c +0 -0
index 097d384..2ae58d0 100644

drivers/s390/char/fs3270.c fs3270_open(struct inode *inode, struct file *filp) · line 471

Quoted 8 lines
drivers/s390/char/fs3270.c +1 -1
@@ -465,7 +465,7 @@ fs3270_open(struct inode *inode, struct file *filp)
 	if (IS_ERR(ib)) {
 		raw3270_put_view(&fp->view);
 		raw3270_del_view(&fp->view);
-		rc = PTR_ERR(fp);
+		rc = PTR_ERR(ib);
 		goto out;
 	}
 	fp->rdbuf = ib;

And added this one as well.

Signature · 4 lines
blue skies,
   Martin.

"Reality continues to ruin my life." - Calvin.