some fixes (also for master)