The Hunsdiecker reaction makes it possible to prepare bromoalkanes from carboxylic acids. In this reaction, the acid is treated with silver nitrate in a basic medium, forming the silver carboxylate. In a later stage, the decarboxylation of the carboxylate occurs by treatment with bromine dissolved in carbon tetrachloride.
hunsdieker01.gif

Note that Hunsdiecker prepares haloalkanes with one carbon less than the starting acid. This carbon is lost in the form of carbon dioxide, in the second stage of the reaction.