and was captured by the Later Tang army and taken by them to Daliang, which fell to Li Cunxu. (Later Liang's last emperor Zhu Zhen committed suicide as the city fell, ending Later Liang, whose territory was taken over by Later Tang.) During Later Tang After Later Liang's fall, Jing Yanguang apparently returned to serve in the army at Bian (which Later Tang converted back to the Tang-established Xuanwu Circuit (), as Later Tang placed its capital at Luoyang, not Daliang). In 927, by which time Li Cunxu's adoptive brother Li Siyuan was emperor, Li Siyuan decided to visit Bian. Then-military governor of Xuanwu, Zhu Shouyin, believed that Li Siyuan was intending to act against him, rebelled, but was quickly defeated, and he committed suicide. Many of Zhu's officers, including Jing, were set to be executed. These executions were set to be carried out by Li Siyuan's son-in-law Shi Jingtang. When Shi saw Jing, however, he took pity on Jing, and secretly released him and told him to flee. Later, apparently after Shi became the military governor of Hedong Circuit (河東, headquartered in modern Taiyuan, Shanxi), Jing came to serve under him as a "guest general" (客將, kejiang). When Shi rebelled against then-emperor Li Congke (Li Siyuan's adoptive son) in 936, Li Congke sent the general Zhang Jingda to siege Hedong's capital Taiyuan. Jing participated in the city's defense and had much accomplishment during the siege, during which Zhang almost, but was never able to, capture the city. Subsequently, Emperor Taizong of Later Tang's northern rival Khitan Empire came to Shi's rescue and defeated Zhang. He then declared Shi the emperor of China (as emperor of a new state of Later Jin). During Later Jin During Shi Jingtang's reign Shi Jingtang commissioned Jing Yanguang as the commander of his infantry. He was also given the honorary titles of acting Situ () and military prefect (團練使, Tuanlianshi) of Guo Prefecture (果州, in modern Nanchong, Sichuan, then ruled by Later Shu). Later (it is unclear whether this was before or after the Khitan/Later Jin forces destroyed Later Tang later in the year, allowing Later Jin to take over Later Tang's territory), he was given the honorary titles of acting Taibao () and military governor of Ningjiang Circuit (寧江, headquartered in modern Chongqing, then also ruled by Later Shu). In 939, Jing was sent out of then-capital Daliang to serve as the military