Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #60 from gerald-lindsly/master

Replica set allocation error in mongo.c
  • Loading branch information...
commit 35d6781ece1931783e36ce246cbd9e284a004b68 2 parents 6c361a4 + dcc2bff
@gjmurakami-10gen gjmurakami-10gen authored
Showing with 1 addition and 0 deletions.
  1. +1 −0  src/mongo.c
View
1  src/mongo.c
@@ -644,6 +644,7 @@ MONGO_EXPORT int mongo_replica_set_client( mongo *conn ) {
/* Primary found, so return. */
else if( conn->replica_set->primary_connected ) {
+ conn->primary = bson_malloc( sizeof( mongo_host_port ) );
strncpy( conn->primary->host, node->host, strlen( node->host ) + 1 );
conn->primary->port = node->port;
return MONGO_OK;
Please sign in to comment.
Something went wrong with that request. Please try again.