Changeset 2510

Show
Ignore:
Timestamp:
09/02/07 18:05:22 (1 year ago)
Author:
dgollub
Message:

Added osync_queue_get_fd() to get the pipe file descriptor of a Queue.
This is needed to call later ./osplugin with anonymous pipes as
argument and finally fork it.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/opensync/ipc/opensync_queue.c

    r2368 r2510  
    953953} 
    954954 
     955/*! @brief Get the path of the fifo for the Queue 
     956 *  
     957 * Get the full path of the fifo for this Queue if fifos used. 
     958 * 
     959 * @param queue The queue to get the file descriptor 
     960 * @returns The full path of the fifo or NULL if no fifos used  
     961 *  
     962 */ 
    955963const char *osync_queue_get_path(OSyncQueue *queue) 
    956964{ 
     
    958966        return queue->name; 
    959967} 
     968 
     969/*! @brief Get the pipe file descriptor of the Queue 
     970 *  
     971 * Get the pipe file descriptor of this Queue if pipes are used. 
     972 * 
     973 * @param queue The queue to get the file descriptor 
     974 * @returns The pipe file descriptor of the queue or -1 if no pipes used or set 
     975 *  
     976 */ 
     977int osync_queue_get_fd(OSyncQueue *queue) 
     978{ 
     979        osync_assert(queue); 
     980        return queue->fd; 
     981} 
  • trunk/opensync/ipc/opensync_queue.h

    r1845 r2510  
    4747OSyncMessage *osync_queue_get_message(OSyncQueue *queue); 
    4848const char *osync_queue_get_path(OSyncQueue *queue); 
     49int osync_queue_get_fd(OSyncQueue *queue); 
    4950 
    5051osync_bool osync_queue_is_alive(OSyncQueue *queue);