remove some warnings and global calls