]> git.proxmox.com Git - mirror_frr.git/blobdiff - lib/csv.c
zebra, lib: fix the ZEBRA_INTERFACE_VRF_UPDATE zapi message
[mirror_frr.git] / lib / csv.c
index ce84783aa6f7570da98027cabbc489a8cf1cd4b6..582106ebd429356cf98b6ff224c0f4e89dc6501a 100644 (file)
--- a/lib/csv.c
+++ b/lib/csv.c
  * with this program; see the file COPYING; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
  */
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
@@ -563,6 +568,8 @@ void csv_decode(csv_t *csv, char *inbuf)
        csv_record_t *rec;
 
        buf = (inbuf) ? inbuf : csv->buf;
+       assert(buf);
+
        pos = strpbrk(buf, "\n");
        while (pos != NULL) {
                rec = calloc(1, sizeof(csv_record_t));