The fortress was returned to Poland as a result of the Treaty of Karlowitz (1699).
Benteng ini dikembalikan kepada Polandia setelah disepakatinya Perjanjian Karlowitz (1699).