From: Michael Vrable Date: Mon, 16 Aug 2010 22:13:53 +0000 (-0700) Subject: Minor bugfixes/tweaks. X-Git-Url: https://git.vrable.net/?a=commitdiff_plain;h=f939d76d54717f98ac2f49f834d8deaab8e5596d;p=bluesky.git Minor bugfixes/tweaks. --- diff --git a/bluesky/cloudlog.c b/bluesky/cloudlog.c index 0c3fb02..3809b00 100644 --- a/bluesky/cloudlog.c +++ b/bluesky/cloudlog.c @@ -288,7 +288,7 @@ void bluesky_cloudlog_flush(BlueSkyFS *fs) state->location.sequence); async->data = bluesky_string_new_from_gstring(state->data); bluesky_store_async_submit(async); - bluesky_store_async_wait(async); + //bluesky_store_async_wait(async); bluesky_store_async_unref(async); state->location.sequence++; diff --git a/bluesky/log.c b/bluesky/log.c index 48f662b..bdf14ff 100644 --- a/bluesky/log.c +++ b/bluesky/log.c @@ -104,7 +104,7 @@ static gboolean log_open(BlueSkyLog *log) } while (log->fd < 0) { - g_snprintf(logname, sizeof(logname), "log-%08d", log->seq_num); + g_snprintf(logname, sizeof(logname), "journal-%08d", log->seq_num); log->fd = openat(log->dirfd, logname, O_CREAT|O_WRONLY|O_EXCL, 0600); if (log->fd < 0 && errno == EEXIST) { fprintf(stderr, "Log file %s already exists...\n", logname); @@ -317,7 +317,7 @@ BlueSkyCacheFile *bluesky_cachefile_lookup(BlueSkyFS *fs, // A request for a local log file if (clouddir < 0) { - logname = g_strdup_printf("log-%08d", log_seq); + logname = g_strdup_printf("journal-%08d", log_seq); } else { logname = g_strdup_printf("log-%08d-%08d", clouddir, log_seq); } diff --git a/bluesky/util.c b/bluesky/util.c index 0d24328..427519c 100644 --- a/bluesky/util.c +++ b/bluesky/util.c @@ -78,7 +78,7 @@ BlueSkyRCStr *bluesky_string_new_from_gstring(GString *s) BlueSkyRCStr *bluesky_string_new_from_mmap(BlueSkyCacheFile *mmap, int offset, gsize len) { - g_assert(offset + len < mmap->len); + g_assert(offset + len <= mmap->len); BlueSkyRCStr *string = g_new(BlueSkyRCStr, 1); string->mmap = mmap;