Initialize variables before resource_int_value().

Submitted by:	Dmitry Luhtionov <dmitryluhtionov@gmail.com>