[PATCH] s390: synthax checking for VIPA addresses fixed
[patch 1/7] s390: synthax checking for VIPA addresses fixed From: Peter Tiedemann <ptiedem@de.ibm.com> - synthax checking for VIPA addresses fixed Signed-off-by: Frank Pavlic <fpavlic@de.ibm.com> diffstat: qeth.h | 65 ++++++++++++++++++++++++++++++++++++++++++++++++------------- qeth_sys.c | 6 ++--- 2 files changed, 55 insertions(+), 16 deletions(-) Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
This commit is contained in:
committed by
Jeff Garzik
parent
2ecc26b87a
commit
bd389b9059
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
*
|
||||
* linux/drivers/s390/net/qeth_sys.c ($Revision: 1.55 $)
|
||||
* linux/drivers/s390/net/qeth_sys.c ($Revision: 1.58 $)
|
||||
*
|
||||
* Linux on zSeries OSA Express and HiperSockets support
|
||||
* This file contains code related to sysfs.
|
||||
@@ -20,7 +20,7 @@
|
||||
#include "qeth_mpc.h"
|
||||
#include "qeth_fs.h"
|
||||
|
||||
const char *VERSION_QETH_SYS_C = "$Revision: 1.55 $";
|
||||
const char *VERSION_QETH_SYS_C = "$Revision: 1.58 $";
|
||||
|
||||
/*****************************************************************************/
|
||||
/* */
|
||||
@@ -1117,7 +1117,7 @@ qeth_parse_ipatoe(const char* buf, enum qeth_prot_versions proto,
|
||||
start = buf;
|
||||
/* get address string */
|
||||
end = strchr(start, '/');
|
||||
if (!end){
|
||||
if (!end || (end-start >= 49)){
|
||||
PRINT_WARN("Invalid format for ipato_addx/delx. "
|
||||
"Use <ip addr>/<mask bits>\n");
|
||||
return -EINVAL;
|
||||
|
Reference in New Issue
Block a user