Updates as of October 2013

Hi Olivier,

Here are some changes I made to the code over the past years. Please pull them to your repository!

Maciej