There you are, showing off your Android and that funky pattern lock feature. But you didn't think that some joker would try too many times and lock your phone for good. Not to bad, since you just need to wait 30 seconds to retry - or?
Not quite, if you do it too often, the phone will lock you out for good and you can only unlock by either wiping your phone or by logging into your Google account. The Google account feature sounds reasonable and easy --- but wait, your Wifi switch is not on (and you can only turn it on when unlocked).
Not all is lost, provided your phone is rooted and you have the Android toolkit installed (if "adb" means something to you, then read on):
Do the following:
> ./adb shell
# sqlite3 data/data/com.android.providers.settings/databases/settings.db
sqlite> update system set value=0 where name='lock_pattern_autolock';
sqlite> update system set value=0 where name='lockscreen.lockedoutpermanently';
The above commands will connect to your settings-database and then disable the autolock as well as reset the permanent lock.