Nifty flatlines near 24,240; crude surge caps gains amid West Asia tensions