]> andersk Git - moira.git/commitdiff
make "none" delete a phone number
authormar <mar>
Thu, 7 Sep 1989 14:10:43 +0000 (14:10 +0000)
committermar <mar>
Thu, 7 Sep 1989 14:10:43 +0000 (14:10 +0000)
clients/passwd/chfn.c

index f0e7aef9c0b19c9d28faccce8f01e7bb45ad41eb..8744a97f2607293058cf435c6e21a7f86d7a8300 100644 (file)
@@ -291,13 +291,13 @@ char *ask(question, def_val, phone_num)
        }
        
        if (phone_num && ok) {
-           for (i = 0; i < strlen(buf); i++) {
-               if (!isdigit(buf[i]) && (buf[i] != '-')) {
+           for (i = 0; i < strlen(result); i++) {
+               if (!isdigit(result[i]) && (result[i] != '-')) {
                    printf("Phone numbers can contain only digits.\n");
                    ok = FALSE;
                    break;
                }
-               if (buf[i] == '-')
+               if (result[i] == '-')
                    dashes = TRUE;
             }
         }
This page took 0.102399 seconds and 5 git commands to generate.