[2005] in Moira Commits

home help back first fref pref prev next nref lref last post

/svn/moira r4144 - trunk/moira/clients/stanley

daemon@ATHENA.MIT.EDU (Garry Zacheiss)
Mon Sep 23 09:23:08 2013

Date: Mon, 23 Sep 2013 09:23:01 -0400
From: Garry Zacheiss <zacheiss@MIT.EDU>
Message-Id: <201309231323.r8NDN1h0029828@drugstore.mit.edu>
To: moira-commits@MIT.EDU
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Author: zacheiss
Date: 2013-09-23 09:23:01 -0400 (Mon, 23 Sep 2013)
New Revision: 4144

Modified:
   trunk/moira/clients/stanley/stanley.c
Log:
Make sure username is non-NULL; handles user creation case.

Modified: trunk/moira/clients/stanley/stanley.c
===================================================================
--- trunk/moira/clients/stanley/stanley.c	2013-09-20 23:37:06 UTC (rev 4143)
+++ trunk/moira/clients/stanley/stanley.c	2013-09-23 13:23:01 UTC (rev 4144)
@@ -347,7 +347,7 @@
   /* Maybe our 'username' is actually an MIT ID number.
    *  If so, resolve it into a username.
    */
-  if ((!info_flag) && (strlen(username) > 8) && (atoi(username) != 0))
+  if ((!info_flag) && (username != NULL && strlen(username) > 8) && (atoi(username) != 0))
     {
       char *argv[27];
       char *args[1];


home help back first fref pref prev next nref lref last post