Indian markets started the day with small gains on Tuesday but gave up all profits towards the end on border tension. The BSE Sensex ended at 38,365.35, losing 51.88 points or 0.14%. The 50-share index Nifty closed at 11,317.35 shedding 37.70 points or 0.33%.