Frozen flux in a superconducting film