Added -w and changed "true" to in infinite loop