seveas/python-hpilo — pull request #8 by kevints (2012-10-12 19:02:04+00:00)
Title: Fix case where returntags is None causes an iteration error

Before:
```
(provisioning)[kevin@...]~/workspace/ilo/python-hpilo% ./hpilo_cli -i -l example example.net.1918.berkeley.edu get_network_settings
Password for example@example.net.1918.berkeley.edu:

Traceback (most recent call last):
File "./hpilo_cli", line 213, in
main()
File "./hpilo_cli", line 155, in main
result = getattr(ilo, method)(**params)
File "/Users/kevin/workspace/ilo/python-hpilo/hpilo.py", line 699, in get_network_settings
return self._info_tag('RIB_INFO', 'GET_NETWORK_SETTINGS')
File "/Users/kevin/workspace/ilo/python-hpilo/hpilo.py", line 468, in _info_tag
for tag in returntag:
TypeError: 'NoneType' object is not iterable
```

After:

```
(provisioning)[kevin@...]~/workspace/ilo/python-hpilo% ./hpilo_cli -i -l example example.net.1918.berkeley.edu get_network_settings
Password for example@example.1918.berkeley.edu:
>>> pprint(my_ilo.get_network_settings())
{'dhcp_dns_server': True,
'dhcp_domain_name': True,
'dhcp_enable': False,
[...]
```