Changeset 13096 for trunk/Nebulous/nebclient/src/nebclient.c
- Timestamp:
- Apr 30, 2007, 5:06:36 PM (19 years ago)
- File:
-
- 1 edited
-
trunk/Nebulous/nebclient/src/nebclient.c (modified) (8 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Nebulous/nebclient/src/nebclient.c
r12963 r13096 4 4 * Copyright (C) 2005 Joshua Hoblitt 5 5 * 6 * $Id: nebclient.c,v 1.4 3 2007-04-23 23:10:07jhoblitt Exp $6 * $Id: nebclient.c,v 1.44 2007-05-01 03:06:36 jhoblitt Exp $ 7 7 */ 8 8 … … 83 83 } 84 84 85 char *nebCreate(nebServer *server, const char *key, unsigned int class, const char *volume, const char *comment, char **URI)85 char *nebCreate(nebServer *server, const char *key, const char *volume, char **URI) 86 86 { 87 87 struct ns1__create_USCOREobjectResponse response; … … 97 97 98 98 if (soap_call_ns1__create_USCOREobject(server->soap, server->endpoint, NULL, 99 (char *)key, class, (char *)volume, (char *)comment, 100 (char **)&response) != SOAP_OK) { 99 (char *)key, (char *)volume, (char **)&response) != SOAP_OK) { 101 100 nebSetServerErr(server); 102 101 … … 123 122 } 124 123 125 int nebOpenCreate(nebServer *server, const char *key, unsigned int class, const char *volume, const char *comment, char **URI)124 int nebOpenCreate(nebServer *server, const char *key, const char *volume, char **URI) 126 125 { 127 126 char *filename; … … 136 135 } 137 136 138 filename = nebCreate(server, key, class, volume, comment, URI);137 filename = nebCreate(server, key, volume, URI); 139 138 140 139 file = open(filename, O_RDWR|O_TRUNC, 0660); … … 522 521 } 523 522 524 destFH = nebOpenCreate(server, newKey, 0, NULL,NULL, NULL);523 destFH = nebOpenCreate(server, newKey, NULL, NULL); 525 524 if (destFH < 0) { 526 525 // propigate nebCreate() error … … 640 639 resultArray = response.result->__ptr; 641 640 642 if (resultElements != 8) {641 if (resultElements != 6) { 643 642 nebSetErr(server, "server didn't return the proper number of stat elements"); 644 643 return NULL; … … 647 646 nullstrncpy(stat->so_id, resultArray[0], 256); 648 647 nullstrncpy(stat->ext_id, resultArray[1], 256); 649 nullstrncpy(stat->class_id, resultArray[2], 256); 650 nullstrncpy(stat->comment, resultArray[3], 256); 651 nullstrncpy(stat->read_lock, resultArray[4], 256); 652 nullstrncpy(stat->write_lock, resultArray[5], 256); 653 nullstrncpy(stat->epoch, resultArray[6], 256); 654 nullstrncpy(stat->mtime, resultArray[7], 256); 648 nullstrncpy(stat->read_lock, resultArray[2], 256); 649 nullstrncpy(stat->write_lock, resultArray[3], 256); 650 nullstrncpy(stat->epoch, resultArray[4], 256); 651 nullstrncpy(stat->mtime, resultArray[5], 256); 655 652 656 653 return stat;
Note:
See TracChangeset
for help on using the changeset viewer.
