fix logic error 'array access results in a null pointer dereference'

![](https://dl.dropboxusercontent.com/u/25357310/socket_rocket_issue_187.png)