fix warnings of non-void return functions

fixes #546 

sorry @f-schmitt-zih, I already fixed before I read your comment