/* This file is part of the Zebra server.
- Copyright (C) 1994-2010 Index Data
+ Copyright (C) 2004-2013 Index Data
Zebra is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free
*/
+#if HAVE_CONFIG_H
+#include <config.h>
+#endif
#include <stdio.h>
#include <string.h>
#include <assert.h>
entry = ci->entries + ci->no_cur;
if (info[0] == sizeof(entry->sysno)+sizeof(entry->mtime))
{
- strcpy(entry->path, name + ci->prelen);
+ strcpy(entry->path, name + ci->prelen);
entry->kind = dirs_file;
memcpy(&entry->sysno, info+1, sizeof(entry->sysno));
- memcpy(&entry->mtime, info+1+sizeof(entry->sysno),
+ memcpy(&entry->mtime, info+1+sizeof(entry->sysno),
sizeof(entry->mtime));
ci->no_cur++;
- }
+ }
else if (info[0] == sizeof(entry->mtime))
{
strcpy(entry->path, name + ci->prelen);
info = dict_lookup(dict, path);
if (info && info[0] == sizeof(entry->sysno)+sizeof(entry->mtime))
{
- strcpy(entry->path, path);
+ strcpy(entry->path, path);
entry->kind = dirs_file;
memcpy(&entry->sysno, info+1, sizeof(entry->sysno));
- memcpy(&entry->mtime, info+1+sizeof(entry->sysno),
+ memcpy(&entry->mtime, info+1+sizeof(entry->sysno),
sizeof(entry->mtime));
p->no_cur++;
}