Some cleanups & fixes.