Changeset 3487:be2ecd9ae926 in roaraudio for libroar/roarx11.c
- Timestamp:
- 02/14/10 17:48:01 (14 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libroar/roarx11.c
r3474 r3487 51 51 } 52 52 53 con->close = 1; 54 55 return con; 56 #else 57 return NULL; 58 #endif 59 } 60 61 struct roar_x11_connection * roar_x11_connect_display(_ROAR_X11_DISPLAY * display) { 62 #ifdef ROAR_HAVE_LIBX11 63 struct roar_x11_connection * con; 64 65 if ( display == NULL ) 66 return NULL; 67 68 if ( (con = roar_mm_malloc(sizeof(struct roar_x11_connection))) == NULL ) 69 return NULL; 70 71 con->close = 0; 72 con->display = display; 73 53 74 return con; 54 75 #else … … 59 80 int roar_x11_disconnect(struct roar_x11_connection * con) { 60 81 #ifdef ROAR_HAVE_LIBX11 61 int ret ;82 int ret = 0; 62 83 63 84 if ( con == NULL ) 64 85 return -1; 65 86 66 ret = XCloseDisplay(con->display); 87 if ( con->close ) 88 ret = XCloseDisplay(con->display); 67 89 68 90 roar_mm_free(con);
Note: See TracChangeset
for help on using the changeset viewer.