1 /* 2 * This file generated automatically from bigreq.xml by c_client.py. 3 * Edit at your peril. 4 */ 5 6 #ifdef HAVE_CONFIG_H 7 #include "config.h" 8 #endif 9 #include <stdlib.h> 10 #include <string.h> 11 #include <assert.h> 12 #include <stddef.h> /* for offsetof() */ 13 #include "xcbext.h" 14 #include "bigreq.h" 15 16 #define ALIGNOF(type) offsetof(struct { char dummy; type member; }, member) 17 18 xcb_extension_t xcb_big_requests_id = { "BIG-REQUESTS", 0 }; 19 20 21 /***************************************************************************** 22 ** 23 ** xcb_big_requests_enable_cookie_t xcb_big_requests_enable 24 ** 25 ** @param xcb_connection_t *c 26 ** @returns xcb_big_requests_enable_cookie_t 27 ** 28 *****************************************************************************/ 29 30 xcb_big_requests_enable_cookie_t 31 xcb_big_requests_enable (xcb_connection_t *c /**< */) 32 { 33 static const xcb_protocol_request_t xcb_req = { 34 /* count */ 2, 35 /* ext */ &xcb_big_requests_id, 36 /* opcode */ XCB_BIG_REQUESTS_ENABLE, 37 /* isvoid */ 0 38 }; 39 40 struct iovec xcb_parts[4]; 41 xcb_big_requests_enable_cookie_t xcb_ret; 42 xcb_big_requests_enable_request_t xcb_out; 43 44 45 xcb_parts[2].iov_base = (char *) &xcb_out; 46 xcb_parts[2].iov_len = sizeof(xcb_out); 47 xcb_parts[3].iov_base = 0; 48 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 49 50 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 51 return xcb_ret; 52 } 53 54 55 /***************************************************************************** 56 ** 57 ** xcb_big_requests_enable_cookie_t xcb_big_requests_enable_unchecked 58 ** 59 ** @param xcb_connection_t *c 60 ** @returns xcb_big_requests_enable_cookie_t 61 ** 62 *****************************************************************************/ 63 64 xcb_big_requests_enable_cookie_t 65 xcb_big_requests_enable_unchecked (xcb_connection_t *c /**< */) 66 { 67 static const xcb_protocol_request_t xcb_req = { 68 /* count */ 2, 69 /* ext */ &xcb_big_requests_id, 70 /* opcode */ XCB_BIG_REQUESTS_ENABLE, 71 /* isvoid */ 0 72 }; 73 74 struct iovec xcb_parts[4]; 75 xcb_big_requests_enable_cookie_t xcb_ret; 76 xcb_big_requests_enable_request_t xcb_out; 77 78 79 xcb_parts[2].iov_base = (char *) &xcb_out; 80 xcb_parts[2].iov_len = sizeof(xcb_out); 81 xcb_parts[3].iov_base = 0; 82 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 83 84 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 85 return xcb_ret; 86 } 87 88 89 /***************************************************************************** 90 ** 91 ** xcb_big_requests_enable_reply_t * xcb_big_requests_enable_reply 92 ** 93 ** @param xcb_connection_t *c 94 ** @param xcb_big_requests_enable_cookie_t cookie 95 ** @param xcb_generic_error_t **e 96 ** @returns xcb_big_requests_enable_reply_t * 97 ** 98 *****************************************************************************/ 99 100 xcb_big_requests_enable_reply_t * 101 xcb_big_requests_enable_reply (xcb_connection_t *c /**< */, 102 xcb_big_requests_enable_cookie_t cookie /**< */, 103 xcb_generic_error_t **e /**< */) 104 { 105 return (xcb_big_requests_enable_reply_t *) xcb_wait_for_reply(c, cookie.sequence, e); 106 } 107 108