arrived home. Al-Afshin seems not to have been involved in this, but he was detected in other intrigues and died in prison in the spring of 841. Caliph al-Mu'tasim fell sick in October 841 and died on 5 January 842. It is said that Theophilos, even though fighting the Arabs built a Baghdad-style palace near the Bosporus. In those days people went about a l'arabe in kaftans and turbans. Even as far as in the normal streets of Ghuangzhou during the era of Tang, the Arab-style kaftan was in fashion. Relations with Bulgaria and Serbia In 836, following the expiration of the 20-year peace treaty between the Empire and Bulgaria, Theophilos ravaged the Bulgarian frontier. The Bulgarians retaliated, and under the leadership of Isbul they reached Adrianople. At this time, if not earlier, the Bulgarians annexed Philippopolis (Plovdiv) and its environs. Khan Malamir died in 836. The peace between the Serbs, Byzantine foederati, and the Bulgars lasted until 839. Vlastimir of Serbia united several tribes, and Theophilos granted the Serbs independence; Vlastimir acknowledged nominal overlordship of the Emperor. The annexation of western Macedonia by the Bulgars changed the political situation. Malamir or his successor may have seen a threat in the Serb consolidation and opted to subjugate them in the midst of the conquest of Slav lands. Another cause might have been that the Byzantines wanted to divert attention so that they could cope with the Slavic uprising in the Peloponnese, meaning they sent the Serbs to instigate the war. It is thought that the rapid extension of Bulgars over Slavs prompted the Serbs to unite into a state. Khan Presian I (r. 836–852) invaded Serbian territory in 839 (see Bulgarian–Serbian Wars). The invasion led to a three-year war, in which Vlastimir was victorious; Presian was heavily defeated, made no territorial gains, and lost many of his men. The Serbs had a tactical advantage in the hills, and the Bulgars were driven out by the army of Vlastimir. The war ended with the death of Theophilos, which released Vlastimir from his obligations to the Byzantine Empire. Death and legacy The health of Theophilos gradually failed, and he died on 20 January 842. His reputation as a judge endured, and in the literary composition Timarion Theophilos is featured as one of the judges in the Netherworld. Theophilos strengthened the Walls of Constantinople, built the fortress of Sarkel on the Don river