pushBackList(attr, newAttr(ATTR_PASSWORD, strlen(nga->password), strdup(nga->password)));
ret = readRequest(nga, attr);
- if (ret == ERR_INVOP) {
+ if (ret == ERR_INVOP || ret == ERR_BADPASS) {
/* it seems some switches do not support login with read request
* fallback to write request, even if it has the drawback of
* the password being broadcasted back by the switch