libsmb: Add cli_smb2_notify
authorVolker Lendecke <vl@samba.org>
Tue, 25 Jul 2017 10:12:02 +0000 (12:12 +0200)
committerKarolin Seeger <kseeger@samba.org>
Fri, 20 Apr 2018 09:53:09 +0000 (11:53 +0200)
commit41666d5992a2a8a15cd46069c88792310eb2af78
tree34f814bc744fd73a5712129e657fbcdbacf7dddd
parent898297b7a1ef4397b018327b83e3f77c709f94f8
libsmb: Add cli_smb2_notify

We have to do the parsing manually. Looking at librpc/gen_ndr/ndr_notify.c we
have the following code snippet:

  size_FileName1_0 = strlen_m(r->FileName1);
  NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->FileName1,
                             size_FileName1_0, sizeof(uint16_t),
                             CH_UTF16));

which means that we take strlen_m(r->FileName1) before we pull
it off the wire. Not sure how to fix this, but that is clearly
broken pidl output. Once that is fixed, we can convert this
to ndr_pull_struct.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=13382
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit 18011343d80a28fb46894d712b22c84dce067342)
source3/libsmb/cli_smb2_fnum.c
source3/libsmb/cli_smb2_fnum.h