rapid7/metasploit-framework — pull request #1748 by schierlm (2013-04-20 21:14:16+00:00)
Title: Fix incorrect network prefix in Java Meterpreter

Apparently, getNetworkPrefixLength can return -1, which confuses the Ruby
side. Therefore fall back to guessing the prefix in this case, as we do it
for Java <= 1.6.

This may cause spurious errors like `warning: in a**b, b may be too big`, and ifconfig command may stop with an error that ~ cannot be applied to -1.