Fixed the same bugs in rpm_post.sh script