some bug fixes. Still need to figure out powering uoff
fixed stack and thread_wait
fixed synchronization in sync and thread. Each time a new thread is scheduled, interrupts will be turned on again
fixed another prob in schedule
added exit to null checks
sanitized malloc in threads
Merge remote-tracking branch 'origin/ben_dev' into ralph_dev