pre-8.0 fixes

This commit is contained in:
vanhauser-thc 2014-04-28 11:04:38 +02:00
parent 76c6145106
commit ebbd664e07
18 changed files with 199 additions and 129 deletions

View file

@ -58,6 +58,7 @@ int start_cisco(int s, char *ip, int port, unsigned char options, char *miscptr,
if (buf != NULL && strstr(buf, "assw") != NULL) {
hydra_completed_pair();
free(buf);
buf = NULL;
if (memcmp(hydra_get_next_pair(), &HYDRA_EXIT, sizeof(HYDRA_EXIT)) == 0)
return 3;
if (strlen(pass = hydra_get_next_password()) == 0)
@ -73,6 +74,8 @@ int start_cisco(int s, char *ip, int port, unsigned char options, char *miscptr,
return 1;
}
do {
if (buf != NULL)
free(buf);
buf = hydra_receive_line(s);
if (buf != NULL) {
if (buf[strlen(buf) - 1] == '\n')