This changed in 1991, when Turkmenistan gained independence and established full control over gas export and export revenues. However, Soviet-era pipelines dictated that much of the gas go to the Caucasus, Russia and Ukraine. In the 1990s many of Turkmenistan's gas customers in the CIS failed to pay on time or negotiated barter deals. In the mid-1990s Turkmenistan stopped delivering gas to some CIS members, citing failure to pay and unprofitable barter deals. At the same time, the government tried to attract investments in building gas pipelines via Iran to Turkey and Western Europe via Afghanistan to Pakistan. Neither deal went through due to an unfavourable regional security environment and high costs; inflation and the budget deficit rose but privatisation was resisted.