fixed return code in main()