Lines Matching refs:login

26 static char *login;
33 login = strdup("");
34 if(!password || !login) {
36 Curl_safefree(login);
45 Curl_safefree(login);
57 result = Curl_parsenetrc("test.example.com", &login, &password, filename);
61 abort_unless(login != NULL, "returned NULL!");
62 fail_unless(login[0] == 0, "login should not have been changed");
65 * Test a non existent login in our netrc file.
67 free(login);
68 login = strdup("me");
69 abort_unless(login != NULL, "returned NULL!");
70 result = Curl_parsenetrc("example.com", &login, &password, filename);
74 abort_unless(login != NULL, "returned NULL!");
75 fail_unless(strncmp(login, "me", 2) == 0,
76 "login should not have been changed");
79 * Test a non existent login and host in our netrc file.
81 free(login);
82 login = strdup("me");
83 abort_unless(login != NULL, "returned NULL!");
84 result = Curl_parsenetrc("test.example.com", &login, &password, filename);
88 abort_unless(login != NULL, "returned NULL!");
89 fail_unless(strncmp(login, "me", 2) == 0,
90 "login should not have been changed");
93 * Test a non existent login (substring of an existing one) in our
96 free(login);
97 login = strdup("admi");
98 abort_unless(login != NULL, "returned NULL!");
99 result = Curl_parsenetrc("example.com", &login, &password, filename);
103 abort_unless(login != NULL, "returned NULL!");
104 fail_unless(strncmp(login, "admi", 4) == 0,
105 "login should not have been changed");
108 * Test a non existent login (superstring of an existing one)
111 free(login);
112 login = strdup("adminn");
113 abort_unless(login != NULL, "returned NULL!");
114 result = Curl_parsenetrc("example.com", &login, &password, filename);
118 abort_unless(login != NULL, "returned NULL!");
119 fail_unless(strncmp(login, "adminn", 6) == 0,
120 "login should not have been changed");
124 * with login[0] = 0.
126 free(login);
127 login = strdup("");
128 abort_unless(login != NULL, "returned NULL!");
129 result = Curl_parsenetrc("example.com", &login, &password, filename);
134 abort_unless(login != NULL, "returned NULL!");
135 fail_unless(strncmp(login, "admin", 5) == 0, "login should be 'admin'");
139 * with login[0] != 0.
144 result = Curl_parsenetrc("example.com", &login, &password, filename);
149 abort_unless(login != NULL, "returned NULL!");
150 fail_unless(strncmp(login, "admin", 5) == 0, "login should be 'admin'");
154 * with login[0] = 0.
159 free(login);
160 login = strdup("");
161 abort_unless(login != NULL, "returned NULL!");
162 result = Curl_parsenetrc("curl.example.com", &login, &password, filename);
167 abort_unless(login != NULL, "returned NULL!");
168 fail_unless(strncmp(login, "none", 4) == 0, "login should be 'none'");
172 * with login[0] != 0.
177 result = Curl_parsenetrc("curl.example.com", &login, &password, filename);
182 abort_unless(login != NULL, "returned NULL!");
183 fail_unless(strncmp(login, "none", 4) == 0, "login should be 'none'");
186 * Test over the size limit password / login!