search for: vfs_handle_set_data

Displaying 2 results from an estimated 2 matches for "vfs_handle_set_data".

2005 Feb 02
0
Re: VFS calls after disconnect
...failed\n")); return -1; } connectCnt ++; data->db_connection = connectCnt ; /* and now store the private data pointer in handle->data * we don't need to specify a free_function here because * we use the connection TALLOC context. * (return -1 if something failed.) */ VFS_HANDLE_SET_DATA(handle, data, NULL, struct example_privates, -1); return 1; }
2004 Feb 17
0
VFS module programmieren
...inter to NULL. Some useful MACROS for handle private data. #define SMB_VFS_HANDLE_GET_DATA(handle, datap, type, ret) { \ if (!(handle)||((datap=(type *)(handle)->data)==NULL)) { \ DEBUG(0,("%s() failed to get vfs_handle->data!\n",FUNCTION_MACRO)); \ ret; \ } \ } #define SMB_VFS_HANDLE_SET_DATA(handle, datap, free_fn, type, ret) { \ if (!(handle)) { \ DEBUG(0,("%s() failed to set handle->data!\n",FUNCTION_MACRO)); \ ret; \ } else { \ if ((handle)->free_data) { \ (handle)->free_data(&(handle)->data); \ } \ (handle)->data = (void *)datap; \ (han...