Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

resolved the conflit in run.sh

git-svn-id: http://svn1.bj.corp.yahoo.com/repos/WebEng/lifesearch/memcacheq@59932 82b2e94c-9313-0410-8ced-81db5252d7f6
  • Loading branch information...
commit 8f247187e9ad5b950172d8b0e13a2d47cda8dd04 1 parent 7c39caa
xunxin authored
Showing with 13 additions and 1 deletion.
  1. +7 −1 bdb.c
  2. +2 −0  memcacheq.c
  3. +4 −0 test/basic.t
View
8 bdb.c
@@ -782,7 +782,13 @@ int bdb_put(char *key, size_t nkey, item *it){
ret = get_queue_db_handle(txn, key, nkey, &queue_rec);
if (ret != 0){
- goto err;
+ if (txn != NULL){
+ txn->abort(txn);
+ }
+ if (settings.verbose > 1) {
+ fprintf(stderr, "bdb_put: %s\n", db_strerror(ret));
+ }
+ return 1;
}
queue_dbp = queue_rec.queue_dbp;
View
2  memcacheq.c
@@ -666,6 +666,8 @@ static void complete_nread(conn *c) {
stats.set_hits++;
STATS_UNLOCK();
out_string(c, "STORED");
+ } else if (ret == 1) {
+ out_string(c, "NOT_FOUND");
} else {
out_string(c, "NOT_STORED");
}
View
4 test/basic.t
@@ -21,6 +21,10 @@ my $ret;
my $err;
my $max_size = 10;
+$ret = memcached_set($memc, $q, 'abc');
+$err = $memc->errstr;
+ok(!$ret, 'not add queue yet.');
+is($err, "NOT FOUND");
$ret = memcached_add($memc, $q, 0);
$err = $memc->errstr;
Please sign in to comment.
Something went wrong with that request. Please try again.