Skip to content
This repository has been archived by the owner on Feb 1, 2022. It is now read-only.

Commit

Permalink
Merge branch 'v1.5'
Browse files Browse the repository at this point in the history
  • Loading branch information
jmikola committed Nov 7, 2014
2 parents bcf5523 + 6497509 commit ab4bc0d
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions api/write.c
Original file line number Diff line number Diff line change
Expand Up @@ -273,15 +273,15 @@ int php_mongo_api_write_add(mongo_buffer *buf, int n, php_mongo_write_item *item

switch (item->type) {
case MONGODB_API_COMMAND_INSERT:
retval = php_mongo_api_insert_add(buf, n, item->write.insert, max_document_size TSRMLS_CC);
retval = php_mongo_api_insert_add(buf, n, item->write.insert_doc, max_document_size TSRMLS_CC);
break;

case MONGODB_API_COMMAND_UPDATE:
retval = php_mongo_api_update_add(buf, n, item->write.update, max_document_size TSRMLS_CC);
retval = php_mongo_api_update_add(buf, n, item->write.update_args, max_document_size TSRMLS_CC);
break;

case MONGODB_API_COMMAND_DELETE:
retval = php_mongo_api_delete_add(buf, n, item->write.delete, max_document_size TSRMLS_CC);
retval = php_mongo_api_delete_add(buf, n, item->write.delete_args, max_document_size TSRMLS_CC);
break;
}

Expand Down
6 changes: 3 additions & 3 deletions api/write.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@ typedef enum {
typedef struct {
php_mongo_write_types type;
union {
HashTable *insert;
php_mongo_write_update_args *update;
php_mongo_write_delete_args *delete;
HashTable *insert_doc;
php_mongo_write_update_args *update_args;
php_mongo_write_delete_args *delete_args;
} write;
} php_mongo_write_item;

Expand Down
6 changes: 3 additions & 3 deletions batch/write.c
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ PHP_METHOD(MongoWriteBatch, add)
write_item.type = intern->batch_type;
switch (intern->batch_type) {
case MONGODB_API_COMMAND_INSERT:
write_item.write.insert = ht_item;
write_item.write.insert_doc = ht_item;
break;

case MONGODB_API_COMMAND_UPDATE: {
Expand Down Expand Up @@ -180,7 +180,7 @@ PHP_METHOD(MongoWriteBatch, add)
update_args.upsert = Z_BVAL_PP(upsert);
}

write_item.write.update = &update_args;
write_item.write.update_args = &update_args;
break;
}

Expand All @@ -202,7 +202,7 @@ PHP_METHOD(MongoWriteBatch, add)
delete_args.query = *q;
delete_args.limit = Z_LVAL_PP(limit);

write_item.write.delete = &delete_args;
write_item.write.delete_args = &delete_args;
break;
}

Expand Down

0 comments on commit ab4bc0d

Please sign in to comment.