Fix bugs from dock stripping.