]> andersk Git - moira.git/commitdiff
check_username_available() should know about the userhistory table.
authorzacheiss <zacheiss>
Thu, 9 Apr 2009 20:25:54 +0000 (20:25 +0000)
committerzacheiss <zacheiss>
Thu, 9 Apr 2009 20:25:54 +0000 (20:25 +0000)
reg_svr/reg_svr.pc

index 79d209ca634e647a8cfe49f29629656bfba5cb7c..a8616151ffd51d6aa1aef305e1a07523b0ad6f2e 100644 (file)
@@ -1006,6 +1006,13 @@ int check_username_available(char *username)
   if (count != 0)
     return MR_IN_USE;
 
+  EXEC SQL SELECT COUNT(login) INTO :count FROM userhistory
+    WHERE login = :username;
+  if (sqlca.sqlcode)
+    return MR_DBMS_ERR;
+  if (count != 0)
+    return MR_IN_USE;
+
   return MR_SUCCESS;
 }
 
This page took 0.031093 seconds and 5 git commands to generate.