LCOV - code coverage report
Current view: top level - bin/default/librpc/gen_ndr - ndr_echo.c (source / functions) Hit Total Coverage
Test: coverage report for abartlet/fix-coverage dd10fb34 Lines: 874 1060 82.5 %
Date: 2021-09-23 10:06:22 Functions: 69 70 98.6 %

          Line data    Source code
       1             : /* parser auto-generated by pidl */
       2             : 
       3             : #include "includes.h"
       4             : #include "bin/default/librpc/gen_ndr/ndr_echo.h"
       5             : 
       6         599 : _PUBLIC_ enum ndr_err_code ndr_push_echo_info1(struct ndr_push *ndr, int ndr_flags, const struct echo_info1 *r)
       7             : {
       8         599 :         NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
       9         599 :         if (ndr_flags & NDR_SCALARS) {
      10         599 :                 NDR_CHECK(ndr_push_align(ndr, 1));
      11         599 :                 NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->v));
      12         599 :                 NDR_CHECK(ndr_push_trailer_align(ndr, 1));
      13             :         }
      14         595 :         if (ndr_flags & NDR_BUFFERS) {
      15             :         }
      16         599 :         return NDR_ERR_SUCCESS;
      17             : }
      18             : 
      19         565 : _PUBLIC_ enum ndr_err_code ndr_pull_echo_info1(struct ndr_pull *ndr, int ndr_flags, struct echo_info1 *r)
      20             : {
      21         565 :         NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
      22         565 :         if (ndr_flags & NDR_SCALARS) {
      23         565 :                 NDR_CHECK(ndr_pull_align(ndr, 1));
      24         565 :                 NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->v));
      25         565 :                 NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
      26             :         }
      27         561 :         if (ndr_flags & NDR_BUFFERS) {
      28             :         }
      29         565 :         return NDR_ERR_SUCCESS;
      30             : }
      31             : 
      32           0 : static void ndr_print_flags_echo_info1(struct ndr_print *ndr, const char *name, int unused, const struct echo_info1 *r)
      33             : {
      34           0 :         ndr_print_echo_info1(ndr, name, r);
      35           0 : }
      36             : 
      37          68 : _PUBLIC_ void ndr_print_echo_info1(struct ndr_print *ndr, const char *name, const struct echo_info1 *r)
      38             : {
      39          68 :         ndr_print_struct(ndr, name, "echo_info1");
      40          68 :         if (r == NULL) { ndr_print_null(ndr); return; }
      41          68 :         ndr->depth++;
      42          68 :         ndr_print_uint8(ndr, "v", r->v);
      43          68 :         ndr->depth--;
      44             : }
      45             : 
      46         299 : static enum ndr_err_code ndr_push_echo_info2(struct ndr_push *ndr, int ndr_flags, const struct echo_info2 *r)
      47             : {
      48         299 :         NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
      49         299 :         if (ndr_flags & NDR_SCALARS) {
      50         299 :                 NDR_CHECK(ndr_push_align(ndr, 2));
      51         299 :                 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->v));
      52         299 :                 NDR_CHECK(ndr_push_trailer_align(ndr, 2));
      53             :         }
      54         297 :         if (ndr_flags & NDR_BUFFERS) {
      55             :         }
      56         299 :         return NDR_ERR_SUCCESS;
      57             : }
      58             : 
      59         282 : static enum ndr_err_code ndr_pull_echo_info2(struct ndr_pull *ndr, int ndr_flags, struct echo_info2 *r)
      60             : {
      61         282 :         NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
      62         282 :         if (ndr_flags & NDR_SCALARS) {
      63         282 :                 NDR_CHECK(ndr_pull_align(ndr, 2));
      64         282 :                 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->v));
      65         282 :                 NDR_CHECK(ndr_pull_trailer_align(ndr, 2));
      66             :         }
      67         280 :         if (ndr_flags & NDR_BUFFERS) {
      68             :         }
      69         282 :         return NDR_ERR_SUCCESS;
      70             : }
      71             : 
      72          34 : _PUBLIC_ void ndr_print_echo_info2(struct ndr_print *ndr, const char *name, const struct echo_info2 *r)
      73             : {
      74          34 :         ndr_print_struct(ndr, name, "echo_info2");
      75          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
      76          34 :         ndr->depth++;
      77          34 :         ndr_print_uint16(ndr, "v", r->v);
      78          34 :         ndr->depth--;
      79             : }
      80             : 
      81         299 : static enum ndr_err_code ndr_push_echo_info3(struct ndr_push *ndr, int ndr_flags, const struct echo_info3 *r)
      82             : {
      83         299 :         NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
      84         299 :         if (ndr_flags & NDR_SCALARS) {
      85         299 :                 NDR_CHECK(ndr_push_align(ndr, 4));
      86         299 :                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->v));
      87         299 :                 NDR_CHECK(ndr_push_trailer_align(ndr, 4));
      88             :         }
      89         297 :         if (ndr_flags & NDR_BUFFERS) {
      90             :         }
      91         299 :         return NDR_ERR_SUCCESS;
      92             : }
      93             : 
      94         282 : static enum ndr_err_code ndr_pull_echo_info3(struct ndr_pull *ndr, int ndr_flags, struct echo_info3 *r)
      95             : {
      96         282 :         NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
      97         282 :         if (ndr_flags & NDR_SCALARS) {
      98         282 :                 NDR_CHECK(ndr_pull_align(ndr, 4));
      99         282 :                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->v));
     100         282 :                 NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
     101             :         }
     102         280 :         if (ndr_flags & NDR_BUFFERS) {
     103             :         }
     104         282 :         return NDR_ERR_SUCCESS;
     105             : }
     106             : 
     107          34 : _PUBLIC_ void ndr_print_echo_info3(struct ndr_print *ndr, const char *name, const struct echo_info3 *r)
     108             : {
     109          34 :         ndr_print_struct(ndr, name, "echo_info3");
     110          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
     111          34 :         ndr->depth++;
     112          34 :         ndr_print_uint32(ndr, "v", r->v);
     113          34 :         ndr->depth--;
     114             : }
     115             : 
     116         598 : static enum ndr_err_code ndr_push_STRUCT_echo_info4(struct ndr_push *ndr, int ndr_flags, const struct echo_info4 *r)
     117             : {
     118         598 :         NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
     119         598 :         if (ndr_flags & NDR_SCALARS) {
     120         598 :                 NDR_CHECK(ndr_push_align(ndr, 8));
     121         598 :                 NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->v));
     122         598 :                 NDR_CHECK(ndr_push_trailer_align(ndr, 8));
     123             :         }
     124         594 :         if (ndr_flags & NDR_BUFFERS) {
     125             :         }
     126         598 :         return NDR_ERR_SUCCESS;
     127             : }
     128             : 
     129         564 : static enum ndr_err_code ndr_pull_STRUCT_echo_info4(struct ndr_pull *ndr, int ndr_flags, struct echo_info4 *r)
     130             : {
     131         564 :         NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
     132         564 :         if (ndr_flags & NDR_SCALARS) {
     133         564 :                 NDR_CHECK(ndr_pull_align(ndr, 8));
     134         564 :                 NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->v));
     135         564 :                 NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
     136             :         }
     137         560 :         if (ndr_flags & NDR_BUFFERS) {
     138             :         }
     139         564 :         return NDR_ERR_SUCCESS;
     140             : }
     141             : 
     142          68 : _PUBLIC_ void ndr_print_STRUCT_echo_info4(struct ndr_print *ndr, const char *name, const struct echo_info4 *r)
     143             : {
     144          68 :         ndr_print_struct(ndr, name, "echo_info4");
     145          68 :         if (r == NULL) { ndr_print_null(ndr); return; }
     146          68 :         ndr->depth++;
     147          68 :         ndr_print_hyper(ndr, "v", r->v);
     148          68 :         ndr->depth--;
     149             : }
     150             : 
     151         299 : static enum ndr_err_code ndr_push_echo_info5(struct ndr_push *ndr, int ndr_flags, const struct echo_info5 *r)
     152             : {
     153         299 :         NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
     154         299 :         if (ndr_flags & NDR_SCALARS) {
     155         299 :                 NDR_CHECK(ndr_push_align(ndr, 8));
     156         299 :                 NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->v1));
     157         299 :                 NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->v2));
     158         299 :                 NDR_CHECK(ndr_push_trailer_align(ndr, 8));
     159             :         }
     160         297 :         if (ndr_flags & NDR_BUFFERS) {
     161             :         }
     162         299 :         return NDR_ERR_SUCCESS;
     163             : }
     164             : 
     165         282 : static enum ndr_err_code ndr_pull_echo_info5(struct ndr_pull *ndr, int ndr_flags, struct echo_info5 *r)
     166             : {
     167         282 :         NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
     168         282 :         if (ndr_flags & NDR_SCALARS) {
     169         282 :                 NDR_CHECK(ndr_pull_align(ndr, 8));
     170         282 :                 NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->v1));
     171         282 :                 NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->v2));
     172         282 :                 NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
     173             :         }
     174         280 :         if (ndr_flags & NDR_BUFFERS) {
     175             :         }
     176         282 :         return NDR_ERR_SUCCESS;
     177             : }
     178             : 
     179          34 : _PUBLIC_ void ndr_print_echo_info5(struct ndr_print *ndr, const char *name, const struct echo_info5 *r)
     180             : {
     181          34 :         ndr_print_struct(ndr, name, "echo_info5");
     182          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
     183          34 :         ndr->depth++;
     184          34 :         ndr_print_uint8(ndr, "v1", r->v1);
     185          34 :         ndr_print_hyper(ndr, "v2", r->v2);
     186          34 :         ndr->depth--;
     187             : }
     188             : 
     189         299 : static enum ndr_err_code ndr_push_echo_info6(struct ndr_push *ndr, int ndr_flags, const struct echo_info6 *r)
     190             : {
     191         299 :         NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
     192         299 :         if (ndr_flags & NDR_SCALARS) {
     193         299 :                 NDR_CHECK(ndr_push_align(ndr, 1));
     194         299 :                 NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->v1));
     195         299 :                 NDR_CHECK(ndr_push_echo_info1(ndr, NDR_SCALARS, &r->info1));
     196         299 :                 NDR_CHECK(ndr_push_trailer_align(ndr, 1));
     197             :         }
     198         297 :         if (ndr_flags & NDR_BUFFERS) {
     199             :         }
     200         299 :         return NDR_ERR_SUCCESS;
     201             : }
     202             : 
     203         282 : static enum ndr_err_code ndr_pull_echo_info6(struct ndr_pull *ndr, int ndr_flags, struct echo_info6 *r)
     204             : {
     205         282 :         NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
     206         282 :         if (ndr_flags & NDR_SCALARS) {
     207         282 :                 NDR_CHECK(ndr_pull_align(ndr, 1));
     208         282 :                 NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->v1));
     209         282 :                 NDR_CHECK(ndr_pull_echo_info1(ndr, NDR_SCALARS, &r->info1));
     210         282 :                 NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
     211             :         }
     212         280 :         if (ndr_flags & NDR_BUFFERS) {
     213             :         }
     214         282 :         return NDR_ERR_SUCCESS;
     215             : }
     216             : 
     217          34 : _PUBLIC_ void ndr_print_echo_info6(struct ndr_print *ndr, const char *name, const struct echo_info6 *r)
     218             : {
     219          34 :         ndr_print_struct(ndr, name, "echo_info6");
     220          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
     221          34 :         ndr->depth++;
     222          34 :         ndr_print_uint8(ndr, "v1", r->v1);
     223          34 :         ndr_print_echo_info1(ndr, "info1", &r->info1);
     224          34 :         ndr->depth--;
     225             : }
     226             : 
     227         299 : static enum ndr_err_code ndr_push_echo_info7(struct ndr_push *ndr, int ndr_flags, const struct echo_info7 *r)
     228             : {
     229         299 :         NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
     230         299 :         if (ndr_flags & NDR_SCALARS) {
     231         299 :                 NDR_CHECK(ndr_push_align(ndr, 8));
     232         299 :                 NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->v1));
     233         299 :                 NDR_CHECK(ndr_push_STRUCT_echo_info4(ndr, NDR_SCALARS, &r->info4));
     234         299 :                 NDR_CHECK(ndr_push_trailer_align(ndr, 8));
     235             :         }
     236         297 :         if (ndr_flags & NDR_BUFFERS) {
     237             :         }
     238         299 :         return NDR_ERR_SUCCESS;
     239             : }
     240             : 
     241         282 : static enum ndr_err_code ndr_pull_echo_info7(struct ndr_pull *ndr, int ndr_flags, struct echo_info7 *r)
     242             : {
     243         282 :         NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
     244         282 :         if (ndr_flags & NDR_SCALARS) {
     245         282 :                 NDR_CHECK(ndr_pull_align(ndr, 8));
     246         282 :                 NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->v1));
     247         282 :                 NDR_CHECK(ndr_pull_STRUCT_echo_info4(ndr, NDR_SCALARS, &r->info4));
     248         282 :                 NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
     249             :         }
     250         280 :         if (ndr_flags & NDR_BUFFERS) {
     251             :         }
     252         282 :         return NDR_ERR_SUCCESS;
     253             : }
     254             : 
     255          34 : _PUBLIC_ void ndr_print_echo_info7(struct ndr_print *ndr, const char *name, const struct echo_info7 *r)
     256             : {
     257          34 :         ndr_print_struct(ndr, name, "echo_info7");
     258          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
     259          34 :         ndr->depth++;
     260          34 :         ndr_print_uint8(ndr, "v1", r->v1);
     261          34 :         ndr_print_STRUCT_echo_info4(ndr, "info4", &r->info4);
     262          34 :         ndr->depth--;
     263             : }
     264             : 
     265        2093 : static enum ndr_err_code ndr_push_echo_Info(struct ndr_push *ndr, int ndr_flags, const union echo_Info *r)
     266             : {
     267             :         uint32_t level;
     268        2093 :         NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
     269        2093 :         if (ndr_flags & NDR_SCALARS) {
     270             :                 /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
     271        2093 :                 NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
     272        2093 :                 NDR_CHECK(ndr_push_union_align(ndr, 8));
     273        2093 :                 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, level));
     274        2093 :                 NDR_CHECK(ndr_push_union_align(ndr, 8));
     275        2093 :                 switch (level) {
     276         299 :                         case 1: {
     277         299 :                                 NDR_CHECK(ndr_push_echo_info1(ndr, NDR_SCALARS, &r->info1));
     278         297 :                         break; }
     279             : 
     280         299 :                         case 2: {
     281         299 :                                 NDR_CHECK(ndr_push_echo_info2(ndr, NDR_SCALARS, &r->info2));
     282         297 :                         break; }
     283             : 
     284         299 :                         case 3: {
     285         299 :                                 NDR_CHECK(ndr_push_echo_info3(ndr, NDR_SCALARS, &r->info3));
     286         297 :                         break; }
     287             : 
     288         299 :                         case 4: {
     289         299 :                                 NDR_CHECK(ndr_push_STRUCT_echo_info4(ndr, NDR_SCALARS, &r->info4));
     290         297 :                         break; }
     291             : 
     292         299 :                         case 5: {
     293         299 :                                 NDR_CHECK(ndr_push_echo_info5(ndr, NDR_SCALARS, &r->info5));
     294         297 :                         break; }
     295             : 
     296         299 :                         case 6: {
     297         299 :                                 NDR_CHECK(ndr_push_echo_info6(ndr, NDR_SCALARS, &r->info6));
     298         297 :                         break; }
     299             : 
     300         299 :                         case 7: {
     301         299 :                                 NDR_CHECK(ndr_push_echo_info7(ndr, NDR_SCALARS, &r->info7));
     302         297 :                         break; }
     303             : 
     304           0 :                         default:
     305           0 :                                 return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
     306             :                 }
     307           0 :         }
     308        2093 :         if (ndr_flags & NDR_BUFFERS) {
     309           0 :                 if (!(ndr_flags & NDR_SCALARS)) {
     310             :                         /* We didn't get it above, and the token is not needed after this. */
     311           0 :                         NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
     312             :                 }
     313           0 :                 switch (level) {
     314           0 :                         case 1:
     315           0 :                         break;
     316             : 
     317           0 :                         case 2:
     318           0 :                         break;
     319             : 
     320           0 :                         case 3:
     321           0 :                         break;
     322             : 
     323           0 :                         case 4:
     324           0 :                         break;
     325             : 
     326           0 :                         case 5:
     327           0 :                         break;
     328             : 
     329           0 :                         case 6:
     330           0 :                         break;
     331             : 
     332           0 :                         case 7:
     333           0 :                         break;
     334             : 
     335           0 :                         default:
     336           0 :                                 return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
     337             :                 }
     338        1267 :         }
     339        2079 :         return NDR_ERR_SUCCESS;
     340             : }
     341             : 
     342        1974 : static enum ndr_err_code ndr_pull_echo_Info(struct ndr_pull *ndr, int ndr_flags, union echo_Info *r)
     343             : {
     344             :         uint32_t level;
     345             :         uint16_t _level;
     346        1974 :         NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
     347        1974 :         if (ndr_flags & NDR_SCALARS) {
     348             :                 /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
     349        1974 :                 NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
     350        1974 :                 NDR_CHECK(ndr_pull_union_align(ndr, 8));
     351        1974 :                 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &_level));
     352        1974 :                 if (_level != level) {
     353           0 :                         return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u for r at %s", _level, __location__);
     354             :                 }
     355        1974 :                 NDR_CHECK(ndr_pull_union_align(ndr, 8));
     356        1974 :                 switch (level) {
     357         282 :                         case 1: {
     358         282 :                                 NDR_CHECK(ndr_pull_echo_info1(ndr, NDR_SCALARS, &r->info1));
     359         280 :                         break; }
     360             : 
     361         282 :                         case 2: {
     362         282 :                                 NDR_CHECK(ndr_pull_echo_info2(ndr, NDR_SCALARS, &r->info2));
     363         280 :                         break; }
     364             : 
     365         282 :                         case 3: {
     366         282 :                                 NDR_CHECK(ndr_pull_echo_info3(ndr, NDR_SCALARS, &r->info3));
     367         280 :                         break; }
     368             : 
     369         282 :                         case 4: {
     370         282 :                                 NDR_CHECK(ndr_pull_STRUCT_echo_info4(ndr, NDR_SCALARS, &r->info4));
     371         280 :                         break; }
     372             : 
     373         282 :                         case 5: {
     374         282 :                                 NDR_CHECK(ndr_pull_echo_info5(ndr, NDR_SCALARS, &r->info5));
     375         280 :                         break; }
     376             : 
     377         282 :                         case 6: {
     378         282 :                                 NDR_CHECK(ndr_pull_echo_info6(ndr, NDR_SCALARS, &r->info6));
     379         280 :                         break; }
     380             : 
     381         282 :                         case 7: {
     382         282 :                                 NDR_CHECK(ndr_pull_echo_info7(ndr, NDR_SCALARS, &r->info7));
     383         280 :                         break; }
     384             : 
     385           0 :                         default:
     386           0 :                                 return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
     387             :                 }
     388           0 :         }
     389        1974 :         if (ndr_flags & NDR_BUFFERS) {
     390           0 :                 if (!(ndr_flags & NDR_SCALARS)) {
     391             :                         /* We didn't get it above, and the token is not needed after this. */
     392           0 :                         NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
     393             :                 }
     394           0 :                 switch (level) {
     395           0 :                         case 1:
     396           0 :                         break;
     397             : 
     398           0 :                         case 2:
     399           0 :                         break;
     400             : 
     401           0 :                         case 3:
     402           0 :                         break;
     403             : 
     404           0 :                         case 4:
     405           0 :                         break;
     406             : 
     407           0 :                         case 5:
     408           0 :                         break;
     409             : 
     410           0 :                         case 6:
     411           0 :                         break;
     412             : 
     413           0 :                         case 7:
     414           0 :                         break;
     415             : 
     416           0 :                         default:
     417           0 :                                 return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
     418             :                 }
     419        1204 :         }
     420        1960 :         return NDR_ERR_SUCCESS;
     421             : }
     422             : 
     423         238 : _PUBLIC_ void ndr_print_echo_Info(struct ndr_print *ndr, const char *name, const union echo_Info *r)
     424             : {
     425             :         uint32_t level;
     426         238 :         level = ndr_print_steal_switch_value(ndr, r);
     427         238 :         ndr_print_union(ndr, name, level, "echo_Info");
     428         238 :         switch (level) {
     429          34 :                 case 1:
     430          34 :                         ndr_print_echo_info1(ndr, "info1", &r->info1);
     431          34 :                 break;
     432             : 
     433          34 :                 case 2:
     434          34 :                         ndr_print_echo_info2(ndr, "info2", &r->info2);
     435          34 :                 break;
     436             : 
     437          34 :                 case 3:
     438          34 :                         ndr_print_echo_info3(ndr, "info3", &r->info3);
     439          34 :                 break;
     440             : 
     441          34 :                 case 4:
     442          34 :                         ndr_print_STRUCT_echo_info4(ndr, "info4", &r->info4);
     443          34 :                 break;
     444             : 
     445          34 :                 case 5:
     446          34 :                         ndr_print_echo_info5(ndr, "info5", &r->info5);
     447          34 :                 break;
     448             : 
     449          34 :                 case 6:
     450          34 :                         ndr_print_echo_info6(ndr, "info6", &r->info6);
     451          34 :                 break;
     452             : 
     453          34 :                 case 7:
     454          34 :                         ndr_print_echo_info7(ndr, "info7", &r->info7);
     455          34 :                 break;
     456             : 
     457           0 :                 default:
     458           0 :                         ndr_print_bad_level(ndr, name, level);
     459             :         }
     460         238 : }
     461             : 
     462        1737 : static enum ndr_err_code ndr_push_echo_Enum1(struct ndr_push *ndr, int ndr_flags, enum echo_Enum1 r)
     463             : {
     464        1749 :         NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
     465        1737 :         return NDR_ERR_SUCCESS;
     466             : }
     467             : 
     468        1686 : static enum ndr_err_code ndr_pull_echo_Enum1(struct ndr_pull *ndr, int ndr_flags, enum echo_Enum1 *r)
     469             : {
     470             :         uint16_t v;
     471        1698 :         NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
     472        1698 :         *r = v;
     473        1686 :         return NDR_ERR_SUCCESS;
     474             : }
     475             : 
     476         102 : _PUBLIC_ void ndr_print_echo_Enum1(struct ndr_print *ndr, const char *name, enum echo_Enum1 r)
     477             : {
     478         102 :         const char *val = NULL;
     479             : 
     480         102 :         switch (r) {
     481          34 :                 case ECHO_ENUM1: val = "ECHO_ENUM1"; break;
     482          68 :                 case ECHO_ENUM2: val = "ECHO_ENUM2"; break;
     483             :         }
     484         102 :         ndr_print_enum(ndr, name, "ENUM", val, r);
     485         102 : }
     486             : 
     487         579 : static enum ndr_err_code ndr_push_echo_Enum1_32(struct ndr_push *ndr, int ndr_flags, enum echo_Enum1_32 r)
     488             : {
     489         583 :         NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
     490         579 :         return NDR_ERR_SUCCESS;
     491             : }
     492             : 
     493         562 : static enum ndr_err_code ndr_pull_echo_Enum1_32(struct ndr_pull *ndr, int ndr_flags, enum echo_Enum1_32 *r)
     494             : {
     495             :         uint32_t v;
     496         566 :         NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
     497         566 :         *r = v;
     498         562 :         return NDR_ERR_SUCCESS;
     499             : }
     500             : 
     501          34 : _PUBLIC_ void ndr_print_echo_Enum1_32(struct ndr_print *ndr, const char *name, enum echo_Enum1_32 r)
     502             : {
     503          34 :         const char *val = NULL;
     504             : 
     505          34 :         switch (r) {
     506          34 :                 case ECHO_ENUM1_32: val = "ECHO_ENUM1_32"; break;
     507           0 :                 case ECHO_ENUM2_32: val = "ECHO_ENUM2_32"; break;
     508             :         }
     509          34 :         ndr_print_enum(ndr, name, "ENUM", val, r);
     510          34 : }
     511             : 
     512         583 : static enum ndr_err_code ndr_push_echo_Enum2(struct ndr_push *ndr, int ndr_flags, const struct echo_Enum2 *r)
     513             : {
     514         583 :         NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
     515         583 :         if (ndr_flags & NDR_SCALARS) {
     516         583 :                 NDR_CHECK(ndr_push_align(ndr, 4));
     517         587 :                 NDR_CHECK(ndr_push_echo_Enum1(ndr, NDR_SCALARS, r->e1));
     518         587 :                 NDR_CHECK(ndr_push_echo_Enum1_32(ndr, NDR_SCALARS, r->e2));
     519         583 :                 NDR_CHECK(ndr_push_trailer_align(ndr, 4));
     520             :         }
     521         579 :         if (ndr_flags & NDR_BUFFERS) {
     522             :         }
     523         583 :         return NDR_ERR_SUCCESS;
     524             : }
     525             : 
     526         566 : static enum ndr_err_code ndr_pull_echo_Enum2(struct ndr_pull *ndr, int ndr_flags, struct echo_Enum2 *r)
     527             : {
     528         566 :         NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
     529         566 :         if (ndr_flags & NDR_SCALARS) {
     530         566 :                 NDR_CHECK(ndr_pull_align(ndr, 4));
     531         570 :                 NDR_CHECK(ndr_pull_echo_Enum1(ndr, NDR_SCALARS, &r->e1));
     532         570 :                 NDR_CHECK(ndr_pull_echo_Enum1_32(ndr, NDR_SCALARS, &r->e2));
     533         566 :                 NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
     534             :         }
     535         562 :         if (ndr_flags & NDR_BUFFERS) {
     536             :         }
     537         566 :         return NDR_ERR_SUCCESS;
     538             : }
     539             : 
     540          34 : _PUBLIC_ void ndr_print_echo_Enum2(struct ndr_print *ndr, const char *name, const struct echo_Enum2 *r)
     541             : {
     542          34 :         ndr_print_struct(ndr, name, "echo_Enum2");
     543          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
     544          34 :         ndr->depth++;
     545          34 :         ndr_print_echo_Enum1(ndr, "e1", r->e1);
     546          34 :         ndr_print_echo_Enum1_32(ndr, "e2", r->e2);
     547          34 :         ndr->depth--;
     548             : }
     549             : 
     550         583 : static enum ndr_err_code ndr_push_echo_Enum3(struct ndr_push *ndr, int ndr_flags, const union echo_Enum3 *r)
     551             : {
     552             :         uint32_t level;
     553         583 :         NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
     554         583 :         if (ndr_flags & NDR_SCALARS) {
     555             :                 /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
     556         583 :                 NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
     557         583 :                 NDR_CHECK(ndr_push_union_align(ndr, 4));
     558         583 :                 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, level));
     559         583 :                 NDR_CHECK(ndr_push_union_align(ndr, 4));
     560         583 :                 switch (level) {
     561         583 :                         case ECHO_ENUM1: {
     562         587 :                                 NDR_CHECK(ndr_push_echo_Enum1(ndr, NDR_SCALARS, r->e1));
     563         579 :                         break; }
     564             : 
     565           0 :                         case ECHO_ENUM2: {
     566           0 :                                 NDR_CHECK(ndr_push_echo_Enum2(ndr, NDR_SCALARS, &r->e2));
     567           0 :                         break; }
     568             : 
     569           0 :                         default:
     570           0 :                                 return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
     571             :                 }
     572           0 :         }
     573         583 :         if (ndr_flags & NDR_BUFFERS) {
     574           0 :                 if (!(ndr_flags & NDR_SCALARS)) {
     575             :                         /* We didn't get it above, and the token is not needed after this. */
     576           0 :                         NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
     577             :                 }
     578           0 :                 switch (level) {
     579           0 :                         case ECHO_ENUM1:
     580           0 :                         break;
     581             : 
     582           0 :                         case ECHO_ENUM2:
     583           0 :                         break;
     584             : 
     585           0 :                         default:
     586           0 :                                 return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
     587             :                 }
     588         355 :         }
     589         579 :         return NDR_ERR_SUCCESS;
     590             : }
     591             : 
     592         566 : static enum ndr_err_code ndr_pull_echo_Enum3(struct ndr_pull *ndr, int ndr_flags, union echo_Enum3 *r)
     593             : {
     594             :         uint32_t level;
     595             :         uint16_t _level;
     596         566 :         NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
     597         566 :         if (ndr_flags & NDR_SCALARS) {
     598             :                 /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
     599         566 :                 NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
     600         566 :                 NDR_CHECK(ndr_pull_union_align(ndr, 4));
     601         566 :                 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &_level));
     602         566 :                 if (_level != level) {
     603           0 :                         return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u for r at %s", _level, __location__);
     604             :                 }
     605         566 :                 NDR_CHECK(ndr_pull_union_align(ndr, 4));
     606         566 :                 switch (level) {
     607         566 :                         case ECHO_ENUM1: {
     608         570 :                                 NDR_CHECK(ndr_pull_echo_Enum1(ndr, NDR_SCALARS, &r->e1));
     609         562 :                         break; }
     610             : 
     611           0 :                         case ECHO_ENUM2: {
     612           0 :                                 NDR_CHECK(ndr_pull_echo_Enum2(ndr, NDR_SCALARS, &r->e2));
     613           0 :                         break; }
     614             : 
     615           0 :                         default:
     616           0 :                                 return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
     617             :                 }
     618           0 :         }
     619         566 :         if (ndr_flags & NDR_BUFFERS) {
     620           0 :                 if (!(ndr_flags & NDR_SCALARS)) {
     621             :                         /* We didn't get it above, and the token is not needed after this. */
     622           0 :                         NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
     623             :                 }
     624           0 :                 switch (level) {
     625           0 :                         case ECHO_ENUM1:
     626           0 :                         break;
     627             : 
     628           0 :                         case ECHO_ENUM2:
     629           0 :                         break;
     630             : 
     631           0 :                         default:
     632           0 :                                 return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
     633             :                 }
     634         346 :         }
     635         562 :         return NDR_ERR_SUCCESS;
     636             : }
     637             : 
     638          34 : _PUBLIC_ void ndr_print_echo_Enum3(struct ndr_print *ndr, const char *name, const union echo_Enum3 *r)
     639             : {
     640             :         uint32_t level;
     641          34 :         level = ndr_print_steal_switch_value(ndr, r);
     642          34 :         ndr_print_union(ndr, name, level, "echo_Enum3");
     643          34 :         switch (level) {
     644          34 :                 case ECHO_ENUM1:
     645          34 :                         ndr_print_echo_Enum1(ndr, "e1", r->e1);
     646          34 :                 break;
     647             : 
     648           0 :                 case ECHO_ENUM2:
     649           0 :                         ndr_print_echo_Enum2(ndr, "e2", &r->e2);
     650           0 :                 break;
     651             : 
     652           0 :                 default:
     653           0 :                         ndr_print_bad_level(ndr, name, level);
     654             :         }
     655          34 : }
     656             : 
     657         585 : static enum ndr_err_code ndr_push_echo_Surrounding(struct ndr_push *ndr, int ndr_flags, const struct echo_Surrounding *r)
     658             : {
     659             :         uint32_t cntr_surrounding_0;
     660         585 :         NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
     661         585 :         if (ndr_flags & NDR_SCALARS) {
     662         585 :                 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->x));
     663         585 :                 NDR_CHECK(ndr_push_align(ndr, 4));
     664         585 :                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->x));
     665       18233 :                 for (cntr_surrounding_0 = 0; cntr_surrounding_0 < (r->x); cntr_surrounding_0++) {
     666       17652 :                         NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->surrounding[cntr_surrounding_0]));
     667             :                 }
     668         585 :                 NDR_CHECK(ndr_push_trailer_align(ndr, 4));
     669             :         }
     670         581 :         if (ndr_flags & NDR_BUFFERS) {
     671             :         }
     672         585 :         return NDR_ERR_SUCCESS;
     673             : }
     674             : 
     675         568 : static enum ndr_err_code ndr_pull_echo_Surrounding(struct ndr_pull *ndr, int ndr_flags, struct echo_Surrounding *r)
     676             : {
     677         568 :         uint32_t size_surrounding_0 = 0;
     678             :         uint32_t cntr_surrounding_0;
     679         568 :         TALLOC_CTX *_mem_save_surrounding_0 = NULL;
     680         568 :         NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
     681         568 :         if (ndr_flags & NDR_SCALARS) {
     682         568 :                 NDR_CHECK(ndr_pull_array_size(ndr, &r->surrounding));
     683         568 :                 NDR_CHECK(ndr_pull_align(ndr, 4));
     684         568 :                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->x));
     685         568 :                 NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->surrounding, &size_surrounding_0));
     686         568 :                 NDR_PULL_ALLOC_N(ndr, r->surrounding, size_surrounding_0);
     687         568 :                 _mem_save_surrounding_0 = NDR_PULL_GET_MEM_CTX(ndr);
     688         568 :                 NDR_PULL_SET_MEM_CTX(ndr, r->surrounding, 0);
     689       17540 :                 for (cntr_surrounding_0 = 0; cntr_surrounding_0 < (size_surrounding_0); cntr_surrounding_0++) {
     690       16972 :                         NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->surrounding[cntr_surrounding_0]));
     691             :                 }
     692         568 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_surrounding_0, 0);
     693         568 :                 if (r->surrounding) {
     694         568 :                         NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->surrounding, r->x));
     695             :                 }
     696         568 :                 NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
     697             :         }
     698         564 :         if (ndr_flags & NDR_BUFFERS) {
     699             :         }
     700         568 :         return NDR_ERR_SUCCESS;
     701             : }
     702             : 
     703          34 : _PUBLIC_ void ndr_print_echo_Surrounding(struct ndr_print *ndr, const char *name, const struct echo_Surrounding *r)
     704             : {
     705             :         uint32_t cntr_surrounding_0;
     706          34 :         ndr_print_struct(ndr, name, "echo_Surrounding");
     707          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
     708          34 :         ndr->depth++;
     709          34 :         ndr_print_uint32(ndr, "x", r->x);
     710          34 :         ndr->print(ndr, "%s: ARRAY(%d)", "surrounding", (int)r->x);
     711          34 :         ndr->depth++;
     712        1394 :         for (cntr_surrounding_0 = 0; cntr_surrounding_0 < (r->x); cntr_surrounding_0++) {
     713        1360 :                 ndr_print_uint16(ndr, "surrounding", r->surrounding[cntr_surrounding_0]);
     714             :         }
     715          34 :         ndr->depth--;
     716          34 :         ndr->depth--;
     717             : }
     718             : 
     719       19591 : static enum ndr_err_code ndr_push_echo_AddOne(struct ndr_push *ndr, int flags, const struct echo_AddOne *r)
     720             : {
     721       19591 :         NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
     722       19591 :         if (flags & NDR_IN) {
     723        9674 :                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.in_data));
     724             :         }
     725       19591 :         if (flags & NDR_OUT) {
     726        9917 :                 if (r->out.out_data == NULL) {
     727           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
     728             :                 }
     729        9917 :                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.out_data));
     730             :         }
     731        8143 :         return NDR_ERR_SUCCESS;
     732             : }
     733             : 
     734       19353 : static enum ndr_err_code ndr_pull_echo_AddOne(struct ndr_pull *ndr, int flags, struct echo_AddOne *r)
     735             : {
     736       19353 :         TALLOC_CTX *_mem_save_out_data_0 = NULL;
     737       19353 :         NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
     738       19353 :         if (flags & NDR_IN) {
     739        9679 :                 NDR_ZERO_STRUCT(r->out);
     740             : 
     741        9679 :                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.in_data));
     742        9679 :                 NDR_PULL_ALLOC(ndr, r->out.out_data);
     743        9679 :                 NDR_ZERO_STRUCTP(r->out.out_data);
     744             :         }
     745       19353 :         if (flags & NDR_OUT) {
     746             : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
     747             : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
     748        9674 :                 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
     749        5964 :                         NDR_PULL_ALLOC(ndr, r->out.out_data);
     750             :                 }
     751        9674 :                 _mem_save_out_data_0 = NDR_PULL_GET_MEM_CTX(ndr);
     752        9674 :                 NDR_PULL_SET_MEM_CTX(ndr, r->out.out_data, LIBNDR_FLAG_REF_ALLOC);
     753        9674 :                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.out_data));
     754        9674 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_out_data_0, LIBNDR_FLAG_REF_ALLOC);
     755             :         }
     756        7905 :         return NDR_ERR_SUCCESS;
     757             : }
     758             : 
     759         476 : _PUBLIC_ void ndr_print_echo_AddOne(struct ndr_print *ndr, const char *name, int flags, const struct echo_AddOne *r)
     760             : {
     761         476 :         ndr_print_struct(ndr, name, "echo_AddOne");
     762         476 :         if (r == NULL) { ndr_print_null(ndr); return; }
     763         476 :         ndr->depth++;
     764         476 :         if (flags & NDR_SET_VALUES) {
     765           0 :                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
     766             :         }
     767         476 :         if (flags & NDR_IN) {
     768           0 :                 ndr_print_struct(ndr, "in", "echo_AddOne");
     769           0 :                 ndr->depth++;
     770           0 :                 ndr_print_uint32(ndr, "in_data", r->in.in_data);
     771           0 :                 ndr->depth--;
     772             :         }
     773         476 :         if (flags & NDR_OUT) {
     774         476 :                 ndr_print_struct(ndr, "out", "echo_AddOne");
     775         476 :                 ndr->depth++;
     776         476 :                 ndr_print_ptr(ndr, "out_data", r->out.out_data);
     777         476 :                 ndr->depth++;
     778         476 :                 ndr_print_uint32(ndr, "out_data", *r->out.out_data);
     779         476 :                 ndr->depth--;
     780         476 :                 ndr->depth--;
     781             :         }
     782         476 :         ndr->depth--;
     783             : }
     784             : 
     785         601 : static enum ndr_err_code ndr_push_echo_EchoData(struct ndr_push *ndr, int flags, const struct echo_EchoData *r)
     786             : {
     787         601 :         NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
     788         601 :         if (flags & NDR_IN) {
     789         292 :                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.len));
     790         292 :                 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.len));
     791         292 :                 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->in.in_data, r->in.len));
     792             :         }
     793         601 :         if (flags & NDR_OUT) {
     794         309 :                 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.len));
     795         309 :                 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->out.out_data, r->in.len));
     796             :         }
     797         595 :         return NDR_ERR_SUCCESS;
     798             : }
     799             : 
     800         584 : static enum ndr_err_code ndr_pull_echo_EchoData(struct ndr_pull *ndr, int flags, struct echo_EchoData *r)
     801             : {
     802         584 :         uint32_t size_in_data_0 = 0;
     803         584 :         uint32_t size_out_data_0 = 0;
     804         584 :         NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
     805         584 :         if (flags & NDR_IN) {
     806         292 :                 NDR_ZERO_STRUCT(r->out);
     807             : 
     808         292 :                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.len));
     809         292 :                 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.in_data));
     810         292 :                 NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->in.in_data, &size_in_data_0));
     811         292 :                 NDR_PULL_ALLOC_N(ndr, r->in.in_data, size_in_data_0);
     812         292 :                 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->in.in_data, size_in_data_0));
     813         292 :                 if (r->in.in_data) {
     814         292 :                         NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->in.in_data, r->in.len));
     815             :                 }
     816             :         }
     817         584 :         if (flags & NDR_OUT) {
     818             : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
     819             : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
     820         292 :                 NDR_CHECK(ndr_pull_array_size(ndr, &r->out.out_data));
     821         292 :                 NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->out.out_data, &size_out_data_0));
     822         292 :                 NDR_PULL_ALLOC_N(ndr, r->out.out_data, size_out_data_0);
     823         292 :                 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->out.out_data, size_out_data_0));
     824         292 :                 if (r->out.out_data) {
     825         292 :                         NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->out.out_data, r->in.len));
     826             :                 }
     827             :         }
     828         578 :         return NDR_ERR_SUCCESS;
     829             : }
     830             : 
     831          34 : _PUBLIC_ void ndr_print_echo_EchoData(struct ndr_print *ndr, const char *name, int flags, const struct echo_EchoData *r)
     832             : {
     833          34 :         ndr_print_struct(ndr, name, "echo_EchoData");
     834          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
     835          34 :         ndr->depth++;
     836          34 :         if (flags & NDR_SET_VALUES) {
     837           0 :                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
     838             :         }
     839          34 :         if (flags & NDR_IN) {
     840           0 :                 ndr_print_struct(ndr, "in", "echo_EchoData");
     841           0 :                 ndr->depth++;
     842           0 :                 ndr_print_uint32(ndr, "len", r->in.len);
     843           0 :                 ndr_print_array_uint8(ndr, "in_data", r->in.in_data, r->in.len);
     844           0 :                 ndr->depth--;
     845             :         }
     846          34 :         if (flags & NDR_OUT) {
     847          34 :                 ndr_print_struct(ndr, "out", "echo_EchoData");
     848          34 :                 ndr->depth++;
     849          34 :                 ndr_print_array_uint8(ndr, "out_data", r->out.out_data, r->in.len);
     850          34 :                 ndr->depth--;
     851             :         }
     852          34 :         ndr->depth--;
     853             : }
     854             : 
     855         585 : static enum ndr_err_code ndr_push_echo_SinkData(struct ndr_push *ndr, int flags, const struct echo_SinkData *r)
     856             : {
     857         585 :         NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
     858         585 :         if (flags & NDR_IN) {
     859         284 :                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.len));
     860         284 :                 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.len));
     861         284 :                 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->in.data, r->in.len));
     862             :         }
     863         581 :         if (flags & NDR_OUT) {
     864             :         }
     865         585 :         return NDR_ERR_SUCCESS;
     866             : }
     867             : 
     868         568 : static enum ndr_err_code ndr_pull_echo_SinkData(struct ndr_pull *ndr, int flags, struct echo_SinkData *r)
     869             : {
     870         568 :         uint32_t size_data_0 = 0;
     871         568 :         NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
     872         568 :         if (flags & NDR_IN) {
     873         284 :                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.len));
     874         284 :                 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.data));
     875         284 :                 NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->in.data, &size_data_0));
     876         284 :                 NDR_PULL_ALLOC_N(ndr, r->in.data, size_data_0);
     877         284 :                 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->in.data, size_data_0));
     878         284 :                 if (r->in.data) {
     879         284 :                         NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->in.data, r->in.len));
     880             :                 }
     881             :         }
     882         564 :         if (flags & NDR_OUT) {
     883             : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
     884             : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
     885             :         }
     886         568 :         return NDR_ERR_SUCCESS;
     887             : }
     888             : 
     889          34 : _PUBLIC_ void ndr_print_echo_SinkData(struct ndr_print *ndr, const char *name, int flags, const struct echo_SinkData *r)
     890             : {
     891          34 :         ndr_print_struct(ndr, name, "echo_SinkData");
     892          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
     893          34 :         ndr->depth++;
     894          34 :         if (flags & NDR_SET_VALUES) {
     895           0 :                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
     896             :         }
     897          34 :         if (flags & NDR_IN) {
     898           0 :                 ndr_print_struct(ndr, "in", "echo_SinkData");
     899           0 :                 ndr->depth++;
     900           0 :                 ndr_print_uint32(ndr, "len", r->in.len);
     901           0 :                 ndr_print_array_uint8(ndr, "data", r->in.data, r->in.len);
     902           0 :                 ndr->depth--;
     903             :         }
     904          34 :         if (flags & NDR_OUT) {
     905          34 :                 ndr_print_struct(ndr, "out", "echo_SinkData");
     906          34 :                 ndr->depth++;
     907          34 :                 ndr->depth--;
     908             :         }
     909          34 :         ndr->depth--;
     910             : }
     911             : 
     912         585 : static enum ndr_err_code ndr_push_echo_SourceData(struct ndr_push *ndr, int flags, const struct echo_SourceData *r)
     913             : {
     914         585 :         NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
     915         585 :         if (flags & NDR_IN) {
     916         284 :                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.len));
     917             :         }
     918         585 :         if (flags & NDR_OUT) {
     919         301 :                 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.len));
     920         301 :                 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->out.data, r->in.len));
     921             :         }
     922         581 :         return NDR_ERR_SUCCESS;
     923             : }
     924             : 
     925         568 : static enum ndr_err_code ndr_pull_echo_SourceData(struct ndr_pull *ndr, int flags, struct echo_SourceData *r)
     926             : {
     927         568 :         uint32_t size_data_0 = 0;
     928         568 :         NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
     929         568 :         if (flags & NDR_IN) {
     930         284 :                 NDR_ZERO_STRUCT(r->out);
     931             : 
     932         284 :                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.len));
     933             :         }
     934         568 :         if (flags & NDR_OUT) {
     935             : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
     936             : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
     937         284 :                 NDR_CHECK(ndr_pull_array_size(ndr, &r->out.data));
     938         284 :                 NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->out.data, &size_data_0));
     939         284 :                 NDR_PULL_ALLOC_N(ndr, r->out.data, size_data_0);
     940         284 :                 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->out.data, size_data_0));
     941         284 :                 if (r->out.data) {
     942         284 :                         NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->out.data, r->in.len));
     943             :                 }
     944             :         }
     945         564 :         return NDR_ERR_SUCCESS;
     946             : }
     947             : 
     948          34 : _PUBLIC_ void ndr_print_echo_SourceData(struct ndr_print *ndr, const char *name, int flags, const struct echo_SourceData *r)
     949             : {
     950          34 :         ndr_print_struct(ndr, name, "echo_SourceData");
     951          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
     952          34 :         ndr->depth++;
     953          34 :         if (flags & NDR_SET_VALUES) {
     954           0 :                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
     955             :         }
     956          34 :         if (flags & NDR_IN) {
     957           0 :                 ndr_print_struct(ndr, "in", "echo_SourceData");
     958           0 :                 ndr->depth++;
     959           0 :                 ndr_print_uint32(ndr, "len", r->in.len);
     960           0 :                 ndr->depth--;
     961             :         }
     962          34 :         if (flags & NDR_OUT) {
     963          34 :                 ndr_print_struct(ndr, "out", "echo_SourceData");
     964          34 :                 ndr->depth++;
     965          34 :                 ndr_print_array_uint8(ndr, "data", r->out.data, r->in.len);
     966          34 :                 ndr->depth--;
     967             :         }
     968          34 :         ndr->depth--;
     969             : }
     970             : 
     971         585 : static enum ndr_err_code ndr_push_echo_TestCall(struct ndr_push *ndr, int flags, const struct echo_TestCall *r)
     972             : {
     973         585 :         NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
     974         585 :         if (flags & NDR_IN) {
     975         285 :                 if (r->in.s1 == NULL) {
     976           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
     977             :                 }
     978         285 :                 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.s1, CH_UTF16)));
     979         285 :                 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
     980         285 :                 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.s1, CH_UTF16)));
     981         285 :                 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.s1, ndr_charset_length(r->in.s1, CH_UTF16), sizeof(uint16_t), CH_UTF16));
     982             :         }
     983         585 :         if (flags & NDR_OUT) {
     984         300 :                 if (r->out.s2 == NULL) {
     985           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
     986             :                 }
     987         300 :                 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.s2));
     988         300 :                 if (*r->out.s2) {
     989         300 :                         NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.s2, CH_UTF16)));
     990         300 :                         NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
     991         300 :                         NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.s2, CH_UTF16)));
     992         300 :                         NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, *r->out.s2, ndr_charset_length(*r->out.s2, CH_UTF16), sizeof(uint16_t), CH_UTF16));
     993             :                 }
     994             :         }
     995         581 :         return NDR_ERR_SUCCESS;
     996             : }
     997             : 
     998         568 : static enum ndr_err_code ndr_pull_echo_TestCall(struct ndr_pull *ndr, int flags, struct echo_TestCall *r)
     999             : {
    1000         568 :         uint32_t size_s1_1 = 0;
    1001         568 :         uint32_t length_s1_1 = 0;
    1002             :         uint32_t _ptr_s2;
    1003         568 :         uint32_t size_s2_2 = 0;
    1004         568 :         uint32_t length_s2_2 = 0;
    1005         568 :         TALLOC_CTX *_mem_save_s2_0 = NULL;
    1006         568 :         TALLOC_CTX *_mem_save_s2_1 = NULL;
    1007         568 :         NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
    1008         568 :         if (flags & NDR_IN) {
    1009         285 :                 NDR_ZERO_STRUCT(r->out);
    1010             : 
    1011         285 :                 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.s1));
    1012         285 :                 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.s1));
    1013         285 :                 NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.s1, &size_s1_1));
    1014         285 :                 NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.s1, &length_s1_1));
    1015         285 :                 if (length_s1_1 > size_s1_1) {
    1016           0 :                         return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_s1_1, length_s1_1);
    1017             :                 }
    1018         285 :                 NDR_CHECK(ndr_check_string_terminator(ndr, length_s1_1, sizeof(uint16_t)));
    1019         285 :                 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.s1, length_s1_1, sizeof(uint16_t), CH_UTF16));
    1020         285 :                 NDR_PULL_ALLOC(ndr, r->out.s2);
    1021         285 :                 NDR_ZERO_STRUCTP(r->out.s2);
    1022             :         }
    1023         568 :         if (flags & NDR_OUT) {
    1024             : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
    1025             : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
    1026         283 :                 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
    1027          20 :                         NDR_PULL_ALLOC(ndr, r->out.s2);
    1028             :                 }
    1029         283 :                 _mem_save_s2_0 = NDR_PULL_GET_MEM_CTX(ndr);
    1030         283 :                 NDR_PULL_SET_MEM_CTX(ndr, r->out.s2, LIBNDR_FLAG_REF_ALLOC);
    1031         283 :                 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_s2));
    1032         283 :                 if (_ptr_s2) {
    1033         283 :                         NDR_PULL_ALLOC(ndr, *r->out.s2);
    1034             :                 } else {
    1035           0 :                         *r->out.s2 = NULL;
    1036             :                 }
    1037         283 :                 if (*r->out.s2) {
    1038         283 :                         _mem_save_s2_1 = NDR_PULL_GET_MEM_CTX(ndr);
    1039         283 :                         NDR_PULL_SET_MEM_CTX(ndr, *r->out.s2, 0);
    1040         283 :                         NDR_CHECK(ndr_pull_array_size(ndr, r->out.s2));
    1041         283 :                         NDR_CHECK(ndr_pull_array_length(ndr, r->out.s2));
    1042         283 :                         NDR_CHECK(ndr_steal_array_size(ndr, (void*)r->out.s2, &size_s2_2));
    1043         283 :                         NDR_CHECK(ndr_steal_array_length(ndr, (void*)r->out.s2, &length_s2_2));
    1044         283 :                         if (length_s2_2 > size_s2_2) {
    1045           0 :                                 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_s2_2, length_s2_2);
    1046             :                         }
    1047         283 :                         NDR_CHECK(ndr_check_string_terminator(ndr, length_s2_2, sizeof(uint16_t)));
    1048         283 :                         NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, r->out.s2, length_s2_2, sizeof(uint16_t), CH_UTF16));
    1049         283 :                         NDR_PULL_SET_MEM_CTX(ndr, _mem_save_s2_1, 0);
    1050             :                 }
    1051         283 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_s2_0, LIBNDR_FLAG_REF_ALLOC);
    1052             :         }
    1053         564 :         return NDR_ERR_SUCCESS;
    1054             : }
    1055             : 
    1056          34 : _PUBLIC_ void ndr_print_echo_TestCall(struct ndr_print *ndr, const char *name, int flags, const struct echo_TestCall *r)
    1057             : {
    1058          34 :         ndr_print_struct(ndr, name, "echo_TestCall");
    1059          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
    1060          34 :         ndr->depth++;
    1061          34 :         if (flags & NDR_SET_VALUES) {
    1062           0 :                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
    1063             :         }
    1064          34 :         if (flags & NDR_IN) {
    1065           0 :                 ndr_print_struct(ndr, "in", "echo_TestCall");
    1066           0 :                 ndr->depth++;
    1067           0 :                 ndr_print_ptr(ndr, "s1", r->in.s1);
    1068           0 :                 ndr->depth++;
    1069           0 :                 ndr_print_string(ndr, "s1", r->in.s1);
    1070           0 :                 ndr->depth--;
    1071           0 :                 ndr->depth--;
    1072             :         }
    1073          34 :         if (flags & NDR_OUT) {
    1074          34 :                 ndr_print_struct(ndr, "out", "echo_TestCall");
    1075          34 :                 ndr->depth++;
    1076          34 :                 ndr_print_ptr(ndr, "s2", r->out.s2);
    1077          34 :                 ndr->depth++;
    1078          34 :                 ndr_print_ptr(ndr, "s2", *r->out.s2);
    1079          34 :                 ndr->depth++;
    1080          34 :                 if (*r->out.s2) {
    1081          34 :                         ndr_print_string(ndr, "s2", *r->out.s2);
    1082             :                 }
    1083          34 :                 ndr->depth--;
    1084          34 :                 ndr->depth--;
    1085          34 :                 ndr->depth--;
    1086             :         }
    1087          34 :         ndr->depth--;
    1088             : }
    1089             : 
    1090        4069 : static enum ndr_err_code ndr_push_echo_TestCall2(struct ndr_push *ndr, int flags, const struct echo_TestCall2 *r)
    1091             : {
    1092        4069 :         NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
    1093        4069 :         if (flags & NDR_IN) {
    1094        1976 :                 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.level));
    1095             :         }
    1096        4069 :         if (flags & NDR_OUT) {
    1097        2093 :                 if (r->out.info == NULL) {
    1098           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
    1099             :                 }
    1100        2093 :                 NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.info, r->in.level));
    1101        2093 :                 NDR_CHECK(ndr_push_echo_Info(ndr, NDR_SCALARS, r->out.info));
    1102        2093 :                 NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
    1103             :         }
    1104        4041 :         return NDR_ERR_SUCCESS;
    1105             : }
    1106             : 
    1107        3950 : static enum ndr_err_code ndr_pull_echo_TestCall2(struct ndr_pull *ndr, int flags, struct echo_TestCall2 *r)
    1108             : {
    1109        3950 :         TALLOC_CTX *_mem_save_info_0 = NULL;
    1110        3950 :         NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
    1111        3950 :         if (flags & NDR_IN) {
    1112        1976 :                 NDR_ZERO_STRUCT(r->out);
    1113             : 
    1114        1976 :                 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.level));
    1115        1976 :                 NDR_PULL_ALLOC(ndr, r->out.info);
    1116        1976 :                 NDR_ZERO_STRUCTP(r->out.info);
    1117             :         }
    1118        3950 :         if (flags & NDR_OUT) {
    1119             : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
    1120             : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
    1121        1974 :                 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
    1122         133 :                         NDR_PULL_ALLOC(ndr, r->out.info);
    1123             :                 }
    1124        1974 :                 _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
    1125        1974 :                 NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
    1126        1974 :                 NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.info, r->in.level));
    1127        1974 :                 NDR_CHECK(ndr_pull_echo_Info(ndr, NDR_SCALARS, r->out.info));
    1128        1974 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
    1129        1974 :                 NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
    1130             :         }
    1131        3922 :         return NDR_ERR_SUCCESS;
    1132             : }
    1133             : 
    1134         238 : _PUBLIC_ void ndr_print_echo_TestCall2(struct ndr_print *ndr, const char *name, int flags, const struct echo_TestCall2 *r)
    1135             : {
    1136         238 :         ndr_print_struct(ndr, name, "echo_TestCall2");
    1137         238 :         if (r == NULL) { ndr_print_null(ndr); return; }
    1138         238 :         ndr->depth++;
    1139         238 :         if (flags & NDR_SET_VALUES) {
    1140           0 :                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
    1141             :         }
    1142         238 :         if (flags & NDR_IN) {
    1143           0 :                 ndr_print_struct(ndr, "in", "echo_TestCall2");
    1144           0 :                 ndr->depth++;
    1145           0 :                 ndr_print_uint16(ndr, "level", r->in.level);
    1146           0 :                 ndr->depth--;
    1147             :         }
    1148         238 :         if (flags & NDR_OUT) {
    1149         238 :                 ndr_print_struct(ndr, "out", "echo_TestCall2");
    1150         238 :                 ndr->depth++;
    1151         238 :                 ndr_print_ptr(ndr, "info", r->out.info);
    1152         238 :                 ndr->depth++;
    1153         238 :                 ndr_print_set_switch_value(ndr, r->out.info, r->in.level);
    1154         238 :                 ndr_print_echo_Info(ndr, "info", r->out.info);
    1155         238 :                 ndr->depth--;
    1156         238 :                 ndr_print_NTSTATUS(ndr, "result", r->out.result);
    1157         238 :                 ndr->depth--;
    1158             :         }
    1159         238 :         ndr->depth--;
    1160             : }
    1161             : 
    1162         291 : static enum ndr_err_code ndr_push_echo_TestSleep(struct ndr_push *ndr, int flags, const struct echo_TestSleep *r)
    1163             : {
    1164         291 :         NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
    1165         291 :         if (flags & NDR_IN) {
    1166         144 :                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.seconds));
    1167             :         }
    1168         291 :         if (flags & NDR_OUT) {
    1169         147 :                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->out.result));
    1170             :         }
    1171         291 :         return NDR_ERR_SUCCESS;
    1172             : }
    1173             : 
    1174         288 : static enum ndr_err_code ndr_pull_echo_TestSleep(struct ndr_pull *ndr, int flags, struct echo_TestSleep *r)
    1175             : {
    1176         288 :         NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
    1177         288 :         if (flags & NDR_IN) {
    1178         144 :                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.seconds));
    1179             :         }
    1180         288 :         if (flags & NDR_OUT) {
    1181             : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
    1182             : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
    1183         144 :                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->out.result));
    1184             :         }
    1185         288 :         return NDR_ERR_SUCCESS;
    1186             : }
    1187             : 
    1188           6 : _PUBLIC_ void ndr_print_echo_TestSleep(struct ndr_print *ndr, const char *name, int flags, const struct echo_TestSleep *r)
    1189             : {
    1190           6 :         ndr_print_struct(ndr, name, "echo_TestSleep");
    1191           6 :         if (r == NULL) { ndr_print_null(ndr); return; }
    1192           6 :         ndr->depth++;
    1193           6 :         if (flags & NDR_SET_VALUES) {
    1194           0 :                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
    1195             :         }
    1196           6 :         if (flags & NDR_IN) {
    1197           0 :                 ndr_print_struct(ndr, "in", "echo_TestSleep");
    1198           0 :                 ndr->depth++;
    1199           0 :                 ndr_print_uint32(ndr, "seconds", r->in.seconds);
    1200           0 :                 ndr->depth--;
    1201             :         }
    1202           6 :         if (flags & NDR_OUT) {
    1203           6 :                 ndr_print_struct(ndr, "out", "echo_TestSleep");
    1204           6 :                 ndr->depth++;
    1205           6 :                 ndr_print_uint32(ndr, "result", r->out.result);
    1206           6 :                 ndr->depth--;
    1207             :         }
    1208           6 :         ndr->depth--;
    1209             : }
    1210             : 
    1211         583 : static enum ndr_err_code ndr_push_echo_TestEnum(struct ndr_push *ndr, int flags, const struct echo_TestEnum *r)
    1212             : {
    1213         583 :         NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
    1214         583 :         if (flags & NDR_IN) {
    1215         284 :                 if (r->in.foo1 == NULL) {
    1216           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
    1217             :                 }
    1218         284 :                 if (r->in.foo2 == NULL) {
    1219           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
    1220             :                 }
    1221         284 :                 if (r->in.foo3 == NULL) {
    1222           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
    1223             :                 }
    1224         286 :                 NDR_CHECK(ndr_push_echo_Enum1(ndr, NDR_SCALARS, *r->in.foo1));
    1225         284 :                 NDR_CHECK(ndr_push_echo_Enum2(ndr, NDR_SCALARS, r->in.foo2));
    1226         284 :                 NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.foo3, *r->in.foo1));
    1227         284 :                 NDR_CHECK(ndr_push_echo_Enum3(ndr, NDR_SCALARS, r->in.foo3));
    1228             :         }
    1229         583 :         if (flags & NDR_OUT) {
    1230         299 :                 if (r->out.foo1 == NULL) {
    1231           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
    1232             :                 }
    1233         299 :                 if (r->out.foo2 == NULL) {
    1234           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
    1235             :                 }
    1236         299 :                 if (r->out.foo3 == NULL) {
    1237           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
    1238             :                 }
    1239         301 :                 NDR_CHECK(ndr_push_echo_Enum1(ndr, NDR_SCALARS, *r->out.foo1));
    1240         299 :                 NDR_CHECK(ndr_push_echo_Enum2(ndr, NDR_SCALARS, r->out.foo2));
    1241         299 :                 NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.foo3, *r->out.foo1));
    1242         299 :                 NDR_CHECK(ndr_push_echo_Enum3(ndr, NDR_SCALARS, r->out.foo3));
    1243             :         }
    1244         579 :         return NDR_ERR_SUCCESS;
    1245             : }
    1246             : 
    1247         566 : static enum ndr_err_code ndr_pull_echo_TestEnum(struct ndr_pull *ndr, int flags, struct echo_TestEnum *r)
    1248             : {
    1249         566 :         TALLOC_CTX *_mem_save_foo1_0 = NULL;
    1250         566 :         TALLOC_CTX *_mem_save_foo2_0 = NULL;
    1251         566 :         TALLOC_CTX *_mem_save_foo3_0 = NULL;
    1252         566 :         NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
    1253         566 :         if (flags & NDR_IN) {
    1254         284 :                 NDR_ZERO_STRUCT(r->out);
    1255             : 
    1256         284 :                 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
    1257         284 :                         NDR_PULL_ALLOC(ndr, r->in.foo1);
    1258             :                 }
    1259         284 :                 _mem_save_foo1_0 = NDR_PULL_GET_MEM_CTX(ndr);
    1260         284 :                 NDR_PULL_SET_MEM_CTX(ndr, r->in.foo1, LIBNDR_FLAG_REF_ALLOC);
    1261         286 :                 NDR_CHECK(ndr_pull_echo_Enum1(ndr, NDR_SCALARS, r->in.foo1));
    1262         284 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_foo1_0, LIBNDR_FLAG_REF_ALLOC);
    1263         284 :                 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
    1264         284 :                         NDR_PULL_ALLOC(ndr, r->in.foo2);
    1265             :                 }
    1266         284 :                 _mem_save_foo2_0 = NDR_PULL_GET_MEM_CTX(ndr);
    1267         284 :                 NDR_PULL_SET_MEM_CTX(ndr, r->in.foo2, LIBNDR_FLAG_REF_ALLOC);
    1268         284 :                 NDR_CHECK(ndr_pull_echo_Enum2(ndr, NDR_SCALARS, r->in.foo2));
    1269         284 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_foo2_0, LIBNDR_FLAG_REF_ALLOC);
    1270         284 :                 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
    1271         284 :                         NDR_PULL_ALLOC(ndr, r->in.foo3);
    1272             :                 }
    1273         284 :                 _mem_save_foo3_0 = NDR_PULL_GET_MEM_CTX(ndr);
    1274         284 :                 NDR_PULL_SET_MEM_CTX(ndr, r->in.foo3, LIBNDR_FLAG_REF_ALLOC);
    1275         284 :                 NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.foo3, *r->in.foo1));
    1276         284 :                 NDR_CHECK(ndr_pull_echo_Enum3(ndr, NDR_SCALARS, r->in.foo3));
    1277         284 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_foo3_0, LIBNDR_FLAG_REF_ALLOC);
    1278         284 :                 NDR_PULL_ALLOC(ndr, r->out.foo1);
    1279         284 :                 *r->out.foo1 = *r->in.foo1;
    1280         284 :                 NDR_PULL_ALLOC(ndr, r->out.foo2);
    1281         284 :                 *r->out.foo2 = *r->in.foo2;
    1282         284 :                 NDR_PULL_ALLOC(ndr, r->out.foo3);
    1283         284 :                 *r->out.foo3 = *r->in.foo3;
    1284             :         }
    1285         566 :         if (flags & NDR_OUT) {
    1286             : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
    1287             :                 if (r->in.foo1 == NULL) {
    1288             :                         NDR_PULL_ALLOC(ndr, r->in.foo1);
    1289             :                         NDR_ZERO_STRUCTP(r->in.foo1);
    1290             :                 }
    1291             :                 if (r->in.foo2 == NULL) {
    1292             :                         NDR_PULL_ALLOC(ndr, r->in.foo2);
    1293             :                         NDR_ZERO_STRUCTP(r->in.foo2);
    1294             :                 }
    1295             :                 if (r->in.foo3 == NULL) {
    1296             :                         NDR_PULL_ALLOC(ndr, r->in.foo3);
    1297             :                         NDR_ZERO_STRUCTP(r->in.foo3);
    1298             :                 }
    1299             : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
    1300         282 :                 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
    1301          19 :                         NDR_PULL_ALLOC(ndr, r->out.foo1);
    1302             :                 }
    1303         282 :                 _mem_save_foo1_0 = NDR_PULL_GET_MEM_CTX(ndr);
    1304         282 :                 NDR_PULL_SET_MEM_CTX(ndr, r->out.foo1, LIBNDR_FLAG_REF_ALLOC);
    1305         284 :                 NDR_CHECK(ndr_pull_echo_Enum1(ndr, NDR_SCALARS, r->out.foo1));
    1306         282 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_foo1_0, LIBNDR_FLAG_REF_ALLOC);
    1307         282 :                 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
    1308          19 :                         NDR_PULL_ALLOC(ndr, r->out.foo2);
    1309             :                 }
    1310         282 :                 _mem_save_foo2_0 = NDR_PULL_GET_MEM_CTX(ndr);
    1311         282 :                 NDR_PULL_SET_MEM_CTX(ndr, r->out.foo2, LIBNDR_FLAG_REF_ALLOC);
    1312         282 :                 NDR_CHECK(ndr_pull_echo_Enum2(ndr, NDR_SCALARS, r->out.foo2));
    1313         282 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_foo2_0, LIBNDR_FLAG_REF_ALLOC);
    1314         282 :                 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
    1315          19 :                         NDR_PULL_ALLOC(ndr, r->out.foo3);
    1316             :                 }
    1317         282 :                 _mem_save_foo3_0 = NDR_PULL_GET_MEM_CTX(ndr);
    1318         282 :                 NDR_PULL_SET_MEM_CTX(ndr, r->out.foo3, LIBNDR_FLAG_REF_ALLOC);
    1319         282 :                 NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.foo3, *r->out.foo1));
    1320         282 :                 NDR_CHECK(ndr_pull_echo_Enum3(ndr, NDR_SCALARS, r->out.foo3));
    1321         282 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_foo3_0, LIBNDR_FLAG_REF_ALLOC);
    1322             :         }
    1323         562 :         return NDR_ERR_SUCCESS;
    1324             : }
    1325             : 
    1326          34 : _PUBLIC_ void ndr_print_echo_TestEnum(struct ndr_print *ndr, const char *name, int flags, const struct echo_TestEnum *r)
    1327             : {
    1328          34 :         ndr_print_struct(ndr, name, "echo_TestEnum");
    1329          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
    1330          34 :         ndr->depth++;
    1331          34 :         if (flags & NDR_SET_VALUES) {
    1332           0 :                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
    1333             :         }
    1334          34 :         if (flags & NDR_IN) {
    1335           0 :                 ndr_print_struct(ndr, "in", "echo_TestEnum");
    1336           0 :                 ndr->depth++;
    1337           0 :                 ndr_print_ptr(ndr, "foo1", r->in.foo1);
    1338           0 :                 ndr->depth++;
    1339           0 :                 ndr_print_echo_Enum1(ndr, "foo1", *r->in.foo1);
    1340           0 :                 ndr->depth--;
    1341           0 :                 ndr_print_ptr(ndr, "foo2", r->in.foo2);
    1342           0 :                 ndr->depth++;
    1343           0 :                 ndr_print_echo_Enum2(ndr, "foo2", r->in.foo2);
    1344           0 :                 ndr->depth--;
    1345           0 :                 ndr_print_ptr(ndr, "foo3", r->in.foo3);
    1346           0 :                 ndr->depth++;
    1347           0 :                 ndr_print_set_switch_value(ndr, r->in.foo3, *r->in.foo1);
    1348           0 :                 ndr_print_echo_Enum3(ndr, "foo3", r->in.foo3);
    1349           0 :                 ndr->depth--;
    1350           0 :                 ndr->depth--;
    1351             :         }
    1352          34 :         if (flags & NDR_OUT) {
    1353          34 :                 ndr_print_struct(ndr, "out", "echo_TestEnum");
    1354          34 :                 ndr->depth++;
    1355          34 :                 ndr_print_ptr(ndr, "foo1", r->out.foo1);
    1356          34 :                 ndr->depth++;
    1357          34 :                 ndr_print_echo_Enum1(ndr, "foo1", *r->out.foo1);
    1358          34 :                 ndr->depth--;
    1359          34 :                 ndr_print_ptr(ndr, "foo2", r->out.foo2);
    1360          34 :                 ndr->depth++;
    1361          34 :                 ndr_print_echo_Enum2(ndr, "foo2", r->out.foo2);
    1362          34 :                 ndr->depth--;
    1363          34 :                 ndr_print_ptr(ndr, "foo3", r->out.foo3);
    1364          34 :                 ndr->depth++;
    1365          34 :                 ndr_print_set_switch_value(ndr, r->out.foo3, *r->out.foo1);
    1366          34 :                 ndr_print_echo_Enum3(ndr, "foo3", r->out.foo3);
    1367          34 :                 ndr->depth--;
    1368          34 :                 ndr->depth--;
    1369             :         }
    1370          34 :         ndr->depth--;
    1371             : }
    1372             : 
    1373         585 : static enum ndr_err_code ndr_push_echo_TestSurrounding(struct ndr_push *ndr, int flags, const struct echo_TestSurrounding *r)
    1374             : {
    1375         585 :         NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
    1376         585 :         if (flags & NDR_IN) {
    1377         285 :                 if (r->in.data == NULL) {
    1378           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
    1379             :                 }
    1380         285 :                 NDR_CHECK(ndr_push_echo_Surrounding(ndr, NDR_SCALARS, r->in.data));
    1381             :         }
    1382         585 :         if (flags & NDR_OUT) {
    1383         300 :                 if (r->out.data == NULL) {
    1384           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
    1385             :                 }
    1386         300 :                 NDR_CHECK(ndr_push_echo_Surrounding(ndr, NDR_SCALARS, r->out.data));
    1387             :         }
    1388         581 :         return NDR_ERR_SUCCESS;
    1389             : }
    1390             : 
    1391         568 : static enum ndr_err_code ndr_pull_echo_TestSurrounding(struct ndr_pull *ndr, int flags, struct echo_TestSurrounding *r)
    1392             : {
    1393         568 :         TALLOC_CTX *_mem_save_data_0 = NULL;
    1394         568 :         NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
    1395         568 :         if (flags & NDR_IN) {
    1396         285 :                 NDR_ZERO_STRUCT(r->out);
    1397             : 
    1398         285 :                 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
    1399         285 :                         NDR_PULL_ALLOC(ndr, r->in.data);
    1400             :                 }
    1401         285 :                 _mem_save_data_0 = NDR_PULL_GET_MEM_CTX(ndr);
    1402         285 :                 NDR_PULL_SET_MEM_CTX(ndr, r->in.data, LIBNDR_FLAG_REF_ALLOC);
    1403         285 :                 NDR_CHECK(ndr_pull_echo_Surrounding(ndr, NDR_SCALARS, r->in.data));
    1404         285 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_data_0, LIBNDR_FLAG_REF_ALLOC);
    1405         285 :                 NDR_PULL_ALLOC(ndr, r->out.data);
    1406         285 :                 *r->out.data = *r->in.data;
    1407             :         }
    1408         568 :         if (flags & NDR_OUT) {
    1409             : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
    1410             :                 if (r->in.data == NULL) {
    1411             :                         NDR_PULL_ALLOC(ndr, r->in.data);
    1412             :                         NDR_ZERO_STRUCTP(r->in.data);
    1413             :                 }
    1414             : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
    1415         283 :                 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
    1416          20 :                         NDR_PULL_ALLOC(ndr, r->out.data);
    1417             :                 }
    1418         283 :                 _mem_save_data_0 = NDR_PULL_GET_MEM_CTX(ndr);
    1419         283 :                 NDR_PULL_SET_MEM_CTX(ndr, r->out.data, LIBNDR_FLAG_REF_ALLOC);
    1420         283 :                 NDR_CHECK(ndr_pull_echo_Surrounding(ndr, NDR_SCALARS, r->out.data));
    1421         283 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_data_0, LIBNDR_FLAG_REF_ALLOC);
    1422             :         }
    1423         564 :         return NDR_ERR_SUCCESS;
    1424             : }
    1425             : 
    1426          34 : _PUBLIC_ void ndr_print_echo_TestSurrounding(struct ndr_print *ndr, const char *name, int flags, const struct echo_TestSurrounding *r)
    1427             : {
    1428          34 :         ndr_print_struct(ndr, name, "echo_TestSurrounding");
    1429          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
    1430          34 :         ndr->depth++;
    1431          34 :         if (flags & NDR_SET_VALUES) {
    1432           0 :                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
    1433             :         }
    1434          34 :         if (flags & NDR_IN) {
    1435           0 :                 ndr_print_struct(ndr, "in", "echo_TestSurrounding");
    1436           0 :                 ndr->depth++;
    1437           0 :                 ndr_print_ptr(ndr, "data", r->in.data);
    1438           0 :                 ndr->depth++;
    1439           0 :                 ndr_print_echo_Surrounding(ndr, "data", r->in.data);
    1440           0 :                 ndr->depth--;
    1441           0 :                 ndr->depth--;
    1442             :         }
    1443          34 :         if (flags & NDR_OUT) {
    1444          34 :                 ndr_print_struct(ndr, "out", "echo_TestSurrounding");
    1445          34 :                 ndr->depth++;
    1446          34 :                 ndr_print_ptr(ndr, "data", r->out.data);
    1447          34 :                 ndr->depth++;
    1448          34 :                 ndr_print_echo_Surrounding(ndr, "data", r->out.data);
    1449          34 :                 ndr->depth--;
    1450          34 :                 ndr->depth--;
    1451             :         }
    1452          34 :         ndr->depth--;
    1453             : }
    1454             : 
    1455         583 : static enum ndr_err_code ndr_push_echo_TestDoublePointer(struct ndr_push *ndr, int flags, const struct echo_TestDoublePointer *r)
    1456             : {
    1457         583 :         NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
    1458         583 :         if (flags & NDR_IN) {
    1459         284 :                 if (r->in.data == NULL) {
    1460           0 :                         return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
    1461             :                 }
    1462         284 :                 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->in.data));
    1463         284 :                 if (*r->in.data) {
    1464         284 :                         NDR_CHECK(ndr_push_unique_ptr(ndr, **r->in.data));
    1465         284 :                         if (**r->in.data) {
    1466         284 :                                 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, ***r->in.data));
    1467             :                         }
    1468             :                 }
    1469             :         }
    1470         583 :         if (flags & NDR_OUT) {
    1471         299 :                 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->out.result));
    1472             :         }
    1473         579 :         return NDR_ERR_SUCCESS;
    1474             : }
    1475             : 
    1476         566 : static enum ndr_err_code ndr_pull_echo_TestDoublePointer(struct ndr_pull *ndr, int flags, struct echo_TestDoublePointer *r)
    1477             : {
    1478             :         uint32_t _ptr_data;
    1479         566 :         TALLOC_CTX *_mem_save_data_0 = NULL;
    1480         566 :         TALLOC_CTX *_mem_save_data_1 = NULL;
    1481         566 :         TALLOC_CTX *_mem_save_data_2 = NULL;
    1482         566 :         NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
    1483         566 :         if (flags & NDR_IN) {
    1484         284 :                 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
    1485         284 :                         NDR_PULL_ALLOC(ndr, r->in.data);
    1486             :                 }
    1487         284 :                 _mem_save_data_0 = NDR_PULL_GET_MEM_CTX(ndr);
    1488         284 :                 NDR_PULL_SET_MEM_CTX(ndr, r->in.data, LIBNDR_FLAG_REF_ALLOC);
    1489         284 :                 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_data));
    1490         284 :                 if (_ptr_data) {
    1491         284 :                         NDR_PULL_ALLOC(ndr, *r->in.data);
    1492             :                 } else {
    1493           0 :                         *r->in.data = NULL;
    1494             :                 }
    1495         284 :                 if (*r->in.data) {
    1496         284 :                         _mem_save_data_1 = NDR_PULL_GET_MEM_CTX(ndr);
    1497         284 :                         NDR_PULL_SET_MEM_CTX(ndr, *r->in.data, 0);
    1498         284 :                         NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_data));
    1499         284 :                         if (_ptr_data) {
    1500         284 :                                 NDR_PULL_ALLOC(ndr, **r->in.data);
    1501             :                         } else {
    1502           0 :                                 **r->in.data = NULL;
    1503             :                         }
    1504         284 :                         if (**r->in.data) {
    1505         284 :                                 _mem_save_data_2 = NDR_PULL_GET_MEM_CTX(ndr);
    1506         284 :                                 NDR_PULL_SET_MEM_CTX(ndr, **r->in.data, 0);
    1507         284 :                                 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, **r->in.data));
    1508         284 :                                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_data_2, 0);
    1509             :                         }
    1510         284 :                         NDR_PULL_SET_MEM_CTX(ndr, _mem_save_data_1, 0);
    1511             :                 }
    1512         284 :                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_data_0, LIBNDR_FLAG_REF_ALLOC);
    1513             :         }
    1514         566 :         if (flags & NDR_OUT) {
    1515             : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
    1516             :                 if (r->in.data == NULL) {
    1517             :                         NDR_PULL_ALLOC(ndr, r->in.data);
    1518             :                         NDR_ZERO_STRUCTP(r->in.data);
    1519             :                 }
    1520             : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
    1521         282 :                 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->out.result));
    1522             :         }
    1523         562 :         return NDR_ERR_SUCCESS;
    1524             : }
    1525             : 
    1526          34 : _PUBLIC_ void ndr_print_echo_TestDoublePointer(struct ndr_print *ndr, const char *name, int flags, const struct echo_TestDoublePointer *r)
    1527             : {
    1528          34 :         ndr_print_struct(ndr, name, "echo_TestDoublePointer");
    1529          34 :         if (r == NULL) { ndr_print_null(ndr); return; }
    1530          34 :         ndr->depth++;
    1531          34 :         if (flags & NDR_SET_VALUES) {
    1532           0 :                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
    1533             :         }
    1534          34 :         if (flags & NDR_IN) {
    1535           0 :                 ndr_print_struct(ndr, "in", "echo_TestDoublePointer");
    1536           0 :                 ndr->depth++;
    1537           0 :                 ndr_print_ptr(ndr, "data", r->in.data);
    1538           0 :                 ndr->depth++;
    1539           0 :                 ndr_print_ptr(ndr, "data", *r->in.data);
    1540           0 :                 ndr->depth++;
    1541           0 :                 if (*r->in.data) {
    1542           0 :                         ndr_print_ptr(ndr, "data", **r->in.data);
    1543           0 :                         ndr->depth++;
    1544           0 :                         if (**r->in.data) {
    1545           0 :                                 ndr_print_uint16(ndr, "data", ***r->in.data);
    1546             :                         }
    1547           0 :                         ndr->depth--;
    1548             :                 }
    1549           0 :                 ndr->depth--;
    1550           0 :                 ndr->depth--;
    1551           0 :                 ndr->depth--;
    1552             :         }
    1553          34 :         if (flags & NDR_OUT) {
    1554          34 :                 ndr_print_struct(ndr, "out", "echo_TestDoublePointer");
    1555          34 :                 ndr->depth++;
    1556          34 :                 ndr_print_uint16(ndr, "result", r->out.result);
    1557          34 :                 ndr->depth--;
    1558             :         }
    1559          34 :         ndr->depth--;
    1560             : }
    1561             : 
    1562             : #ifndef SKIP_NDR_TABLE_rpcecho
    1563             : static const struct ndr_interface_public_struct rpcecho_public_structs[] = {
    1564             :         {
    1565             :                 .name = "echo_info1",
    1566             :                 .struct_size = sizeof(struct echo_info1 ),
    1567             :                 .ndr_push = (ndr_push_flags_fn_t) ndr_push_echo_info1,
    1568             :                 .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_echo_info1,
    1569             :                 .ndr_print = (ndr_print_function_t) ndr_print_flags_echo_info1,
    1570             :         },
    1571             :         { .name = NULL }
    1572             : };
    1573             : 
    1574             : static const struct ndr_interface_call rpcecho_calls[] = {
    1575             :         {
    1576             :                 "echo_AddOne",
    1577             :                 sizeof(struct echo_AddOne),
    1578             :                 (ndr_push_flags_fn_t) ndr_push_echo_AddOne,
    1579             :                 (ndr_pull_flags_fn_t) ndr_pull_echo_AddOne,
    1580             :                 (ndr_print_function_t) ndr_print_echo_AddOne,
    1581             :                 { 0, NULL },
    1582             :                 { 0, NULL },
    1583             :         },
    1584             :         {
    1585             :                 "echo_EchoData",
    1586             :                 sizeof(struct echo_EchoData),
    1587             :                 (ndr_push_flags_fn_t) ndr_push_echo_EchoData,
    1588             :                 (ndr_pull_flags_fn_t) ndr_pull_echo_EchoData,
    1589             :                 (ndr_print_function_t) ndr_print_echo_EchoData,
    1590             :                 { 0, NULL },
    1591             :                 { 0, NULL },
    1592             :         },
    1593             :         {
    1594             :                 "echo_SinkData",
    1595             :                 sizeof(struct echo_SinkData),
    1596             :                 (ndr_push_flags_fn_t) ndr_push_echo_SinkData,
    1597             :                 (ndr_pull_flags_fn_t) ndr_pull_echo_SinkData,
    1598             :                 (ndr_print_function_t) ndr_print_echo_SinkData,
    1599             :                 { 0, NULL },
    1600             :                 { 0, NULL },
    1601             :         },
    1602             :         {
    1603             :                 "echo_SourceData",
    1604             :                 sizeof(struct echo_SourceData),
    1605             :                 (ndr_push_flags_fn_t) ndr_push_echo_SourceData,
    1606             :                 (ndr_pull_flags_fn_t) ndr_pull_echo_SourceData,
    1607             :                 (ndr_print_function_t) ndr_print_echo_SourceData,
    1608             :                 { 0, NULL },
    1609             :                 { 0, NULL },
    1610             :         },
    1611             :         {
    1612             :                 "echo_TestCall",
    1613             :                 sizeof(struct echo_TestCall),
    1614             :                 (ndr_push_flags_fn_t) ndr_push_echo_TestCall,
    1615             :                 (ndr_pull_flags_fn_t) ndr_pull_echo_TestCall,
    1616             :                 (ndr_print_function_t) ndr_print_echo_TestCall,
    1617             :                 { 0, NULL },
    1618             :                 { 0, NULL },
    1619             :         },
    1620             :         {
    1621             :                 "echo_TestCall2",
    1622             :                 sizeof(struct echo_TestCall2),
    1623             :                 (ndr_push_flags_fn_t) ndr_push_echo_TestCall2,
    1624             :                 (ndr_pull_flags_fn_t) ndr_pull_echo_TestCall2,
    1625             :                 (ndr_print_function_t) ndr_print_echo_TestCall2,
    1626             :                 { 0, NULL },
    1627             :                 { 0, NULL },
    1628             :         },
    1629             :         {
    1630             :                 "echo_TestSleep",
    1631             :                 sizeof(struct echo_TestSleep),
    1632             :                 (ndr_push_flags_fn_t) ndr_push_echo_TestSleep,
    1633             :                 (ndr_pull_flags_fn_t) ndr_pull_echo_TestSleep,
    1634             :                 (ndr_print_function_t) ndr_print_echo_TestSleep,
    1635             :                 { 0, NULL },
    1636             :                 { 0, NULL },
    1637             :         },
    1638             :         {
    1639             :                 "echo_TestEnum",
    1640             :                 sizeof(struct echo_TestEnum),
    1641             :                 (ndr_push_flags_fn_t) ndr_push_echo_TestEnum,
    1642             :                 (ndr_pull_flags_fn_t) ndr_pull_echo_TestEnum,
    1643             :                 (ndr_print_function_t) ndr_print_echo_TestEnum,
    1644             :                 { 0, NULL },
    1645             :                 { 0, NULL },
    1646             :         },
    1647             :         {
    1648             :                 "echo_TestSurrounding",
    1649             :                 sizeof(struct echo_TestSurrounding),
    1650             :                 (ndr_push_flags_fn_t) ndr_push_echo_TestSurrounding,
    1651             :                 (ndr_pull_flags_fn_t) ndr_pull_echo_TestSurrounding,
    1652             :                 (ndr_print_function_t) ndr_print_echo_TestSurrounding,
    1653             :                 { 0, NULL },
    1654             :                 { 0, NULL },
    1655             :         },
    1656             :         {
    1657             :                 "echo_TestDoublePointer",
    1658             :                 sizeof(struct echo_TestDoublePointer),
    1659             :                 (ndr_push_flags_fn_t) ndr_push_echo_TestDoublePointer,
    1660             :                 (ndr_pull_flags_fn_t) ndr_pull_echo_TestDoublePointer,
    1661             :                 (ndr_print_function_t) ndr_print_echo_TestDoublePointer,
    1662             :                 { 0, NULL },
    1663             :                 { 0, NULL },
    1664             :         },
    1665             :         { .name = NULL }
    1666             : };
    1667             : 
    1668             : static const char * const rpcecho_endpoint_strings[] = {
    1669             :         "ncacn_np:[\\pipe\\rpcecho]", 
    1670             :         "ncacn_ip_tcp:", 
    1671             :         "ncalrpc:", 
    1672             : };
    1673             : 
    1674             : static const struct ndr_interface_string_array rpcecho_endpoints = {
    1675             :         .count  = 3,
    1676             :         .names  = rpcecho_endpoint_strings
    1677             : };
    1678             : 
    1679             : static const char * const rpcecho_authservice_strings[] = {
    1680             :         "host", 
    1681             : };
    1682             : 
    1683             : static const struct ndr_interface_string_array rpcecho_authservices = {
    1684             :         .count  = 1,
    1685             :         .names  = rpcecho_authservice_strings
    1686             : };
    1687             : 
    1688             : 
    1689             : const struct ndr_interface_table ndr_table_rpcecho = {
    1690             :         .name           = "rpcecho",
    1691             :         .syntax_id      = {
    1692             :                 {0x60a15ec5,0x4de8,0x11d7,{0xa6,0x37},{0x00,0x50,0x56,0xa2,0x01,0x82}},
    1693             :                 NDR_RPCECHO_VERSION
    1694             :         },
    1695             :         .helpstring     = NDR_RPCECHO_HELPSTRING,
    1696             :         .num_calls      = 10,
    1697             :         .calls          = rpcecho_calls,
    1698             :         .num_public_structs     = 1,
    1699             :         .public_structs         = rpcecho_public_structs,
    1700             :         .endpoints      = &rpcecho_endpoints,
    1701             :         .authservices   = &rpcecho_authservices
    1702             : };
    1703             : 
    1704             : #endif /* SKIP_NDR_TABLE_rpcecho */

Generated by: LCOV version 1.13