On September 28, 1939, the German-Soviet Frontier Treaty is signed by Joachim von Ribbentrop and Vyacheslav Molotov; it redrew German and Soviet spheres of influence in central Europe and transfered most of Lithuania to the USSR. From the article:
"The German–Soviet Frontier Treaty was a second supplementary protocol,[1] of the Molotov–Ribbentrop Pact of 23 August.[2] It was a secret clause as amended on September 28, 1939 by Nazi Germany and the Soviet Union after their joint invasion and occupation of sovereign Poland.[3] It was signed by Joachim von Ribbentrop and Vyacheslav Molotov, the foreign ministers of Germany and the Soviet Union respectively, in the presence of Joseph Stalin. Only a small portion of the protocol, which superseded the first treaty, was publicly announced while the spheres of influence of Nazi Germany and the Soviet Union remained classified. The third secret protocol of the Pact was signed on January 10, 1941 by Friedrich Werner von Schulenberg, and Molotov, wherein Germany renounced its claims to portions of Lithuania, only a few months before their anti-Soviet Operation Barbarossa.[4]
Several secret articles were attached to the treaty. These articles allowed for the exchange of Soviet and German nationals between the two occupied zones of Poland, redrew parts of the central European spheres of interest dictated by the Molotov–Ribbentrop Pact, and also stated that neither party to the treaty would allow on its territory any "Polish agitation" directed at the other party.
During the western invasion of Poland, the German Wehrmacht had taken control of the Lublin Voivodeship and eastern Warsaw Voivodeship - territories which according to the Molotov–Ribbentrop Pact were in the Soviet sphere of influence. To compensate the Soviet Union for this "loss", the treaty's secret attachment transferred Lithuania to the Soviet sphere of influence, with the exception of a small territory in the Suwałki Region, sometimes known as the Suwałki Triangle. After this transfer, the Soviet Union issued an ultimatum to Lithuania, occupied it on June 15, 1940 and established the Lithuanian SSR."