Removed libmagic dependency code