return 1; } variableBindings.list[variableBindings.len - 1].name=reqObject; variableBindings.list[variableBindings.len - 1].value.asnType=ASN_NULL; } // Make sure only one variable binding was specified if operation is WALK. if (operation == WALK && variableBindings.len != 1) { printf("Error: Multiple oids specified for WALK.\n"); return 1; } // Establish a SNMP session to communicate with the remote agent. The // community, communications timeout, and communications retry count // for the session are also required. if ((session = SnmpMgrOpen(agent, community, timeout, retries)) == NULL) { printf("error on SnmpMgrOpen %d\n", GetLastError()); return 1; } } // end if