[DRBD-cvs] svn commit by phil - r2563 - trunk/user - A minor annoyance. If you do # drbdsetup /dev/somedevic

drbd-cvs at lists.linbit.com drbd-cvs at lists.linbit.com
Tue Oct 24 14:41:42 CEST 2006


Author: phil
Date: 2006-10-24 14:41:41 +0200 (Tue, 24 Oct 2006)
New Revision: 2563

Modified:
   trunk/user/drbdsetup.c
Log:
A minor annoyance.  If you do 
# drbdsetup /dev/somedevice secondary -bogus_option 
one get a SEGV. I include a possible patch to fix this.
 
EM--


Modified: trunk/user/drbdsetup.c
===================================================================
--- trunk/user/drbdsetup.c	2006-10-24 12:06:58 UTC (rev 2562)
+++ trunk/user/drbdsetup.c	2006-10-24 12:41:41 UTC (rev 2563)
@@ -690,6 +690,7 @@
 
 struct drbd_option *find_opt_by_short_name(struct drbd_option *od, int c)
 {
+	if(!od) return NULL;
 	while(od->name) {
 		if(od->short_name == c) return od;
 		od++;



More information about the drbd-cvs mailing list