PCRE2_SERIALIZE_DECODE(3) Library Functions Manual PCRE2_SERIALIZE_DECODE(3) NNAAMMEE PCRE2 - Perl-compatible regular expressions (revised API) SSYYNNOOPPSSIISS ##iinncclluuddee <
> iinntt3322__tt ppccrree22__sseerriiaalliizzee__ddeeccooddee((ppccrree22__ccooddee ****_c_o_d_e_s,, iinntt3322__tt _n_u_m_b_e_r___o_f___c_o_d_e_s,, ccoonnsstt uuiinntt88__tt **_b_y_t_e_s,, ppccrree22__ggeenneerraall__ccoonntteexxtt **_g_c_o_n_t_e_x_t));; DDEESSCCRRIIPPTTIIOONN This function decodes a serialized set of compiled patterns back into a list of individual patterns. Its arguments are: _c_o_d_e_s pointer to a vector in which to build the list _n_u_m_b_e_r___o_f___c_o_d_e_s number of slots in the vector _b_y_t_e_s the serialized byte stream _g_c_o_n_t_e_x_t pointer to a general context or NULL The _b_y_t_e_s argument must point to a block of data that was originally created by ppccrree22__sseerriiaalliizzee__eennccooddee(()), though it may have been saved on disc or elsewhere in the meantime. If there are more codes in the seri- alized data than slots in the list, only those compiled patterns that will fit are decoded. The yield of the function is the number of decoded patterns, or one of the following negative error codes: PCRE2_ERROR_BADDATA _n_u_m_b_e_r___o_f___c_o_d_e_s is zero or less PCRE2_ERROR_BADMAGIC mismatch of id bytes in _b_y_t_e_s PCRE2_ERROR_BADMODE mismatch of variable unit size or PCRE version PCRE2_ERROR_MEMORY memory allocation failed PCRE2_ERROR_NULL _c_o_d_e_s or _b_y_t_e_s is NULL PCRE2_ERROR_BADMAGIC may mean that the data is corrupt, or that it was compiled on a system with different endianness. There is a complete description of the PCRE2 native API in the ppccrree22aappii page and a description of the POSIX API in the ppccrree22ppoossiixx page. PCRE2 10.21 02 September 2015 PCRE2_SERIALIZE_DECODE(3)