* Change print to dprintf to avoid buffer overflow * Add stdio header for dprintf * Fix included headers