when did the war of 1812 officially end