Yes. Unlike the lock code itself (which is saved in CAL), the setting to activate the lock is stored in GConf (/system/osso/dsm/locks/devicelock_autolock_enabled), which of course is not stored when reflashing.