When the pendulum oscillates in the air, the air friction opposes its motion. So some part of the kinetic energy of the pendulum is used to overcome this friction. With the passage of time, kinetic energy of the pendulum goes on decreasing and finally becomes zero. The kinetic energy of the pendulum is transferred to the atmosphere. So energy is being transferred ie it is converted into one form to another. So here is no violation of the law of conservation of energy.