--- 
+++ 
@@ -25,7 +25,7 @@
      * @return a copy of the header map that iterates in column order.
      */
     public Map<String, Integer> getHeaderMap() {
-        return new LinkedHashMap<String, Integer>(this.headerMap);
+        return this.headerMap == null? null : new LinkedHashMap<String, Integer>(this.headerMap);
     }
 
     /**