In a finally block, make sure nothing can throw an exception or you would lose the original exception.
For example use a method:
static void close(Closable c) {
 if (c!=null) {
   try {
     c.close();
   } catch (IOException e) {
     LOG.warn(e);
   }
 }
}

and then
 close(br);
 close(writer);