Advertisement
Guest User

Untitled

a guest
Sep 20th, 2014
195
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. int rtable_add(RESIZABLE_TABLE * table, char * name, void * value) {
  2.  
  3. table->array[table->currentElements].name = strdup(name);
  4. table->array[table->currentElements].value = value;
  5. table->currentElements++;
  6. int i = 0;
  7. for(i = 0; i < table->currentElements;i++) {
  8. if(strcmp(table->array[i].name, name) == 0) {
  9. table->array[i].value = value;
  10. }
  11. }
  12. return 0;
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement