diff options
author | default <nobody@localhost> | 2023-12-11 10:41:41 +0100 |
---|---|---|
committer | default <nobody@localhost> | 2023-12-11 10:41:41 +0100 |
commit | bfdaf380eae4358b88d215a7bc1310fbd12b9e5e (patch) | |
tree | 51824940b3cefbe343e637cbce5fa216d207e96e /data.c | |
parent | c06b74cc8e7ab92002ceea9f30d2c8a334a9d1c2 (diff) |
More logging tweaks.
Diffstat (limited to 'data.c')
-rw-r--r-- | data.c | 12 |
1 files changed, 8 insertions, 4 deletions
@@ -649,10 +649,14 @@ int _object_add(const char *id, const xs_dict *obj, int ow) xs *fn = _object_fn(id); FILE *f; - if (!ow && mtime(fn) > 0.0) { - /* object already here */ - srv_debug(1, xs_fmt("object_add object already here %s", id)); - return 204; /* No content */ + if (mtime(fn) > 0.0) { + if (!ow) { + /* object already here */ + srv_debug(1, xs_fmt("object_add object already here %s", id)); + return 204; /* No content */ + } + else + status = 200; } if ((f = fopen(fn, "w")) != NULL) { |