There are many aspects to a strategic tie up between two countries, religion alone accounts for very little between these two countries.
The relationship between India and Indonesia is primarily financial and the defense ties are due to common weapons platform and the ability of common cooperation on fronts like training, counter terrorism, safety of trade routes, and the ties will continue to get stronger with time along with Indonesia china defense ties, the world doesn't run on the cold war principals (except in the case of india & pakistan) it is possible to have relations with two nations.
Traditionally there has been a very tense political relationship between China and ASEAN (excluding Burma) which has only begun to stabilize after the rapid increase in trade volume coming out of and going into china, however it is still years before the political and business rivalry with china is forgotten and Indonesia has only restored relations with the People's Republic of China in 1990.
India herself has seen a rapid growth in business ties with ASEAN (especially Singapore) in recent times. That coupled with the very well known fact that Indian Navy and cost guards play an important role in securing the vital Indian oceans security, ties between India and other ASEAN nations are natural.