[SCM] Samba Shared Repository - branch master updated

2023-09-05 Thread Andrew Bartlett
The branch, master has been updated
   via  f3c632e74ba testprogs: Add net offlinejoin composeodj tests
   via  e92e4b95442 testprogs: Cleanup machine account in net offlinejoin 
tests
   via  c14a4f51443 s3:net: Allow to load ODJ blob from stdin
   via  b2399b6994c s3:net: Load ODJ blob from file only if "loadfile" 
parameter is present
   via  4a1f2071a60 s3:net: Add "net offlinejoin composeodj" command
   via  a8bd8f22aac s3:libnetapi: Implement NetComposeOfflineDomainJoin_l()
   via  7cabbec2eaf s3:libnetapi: Add NetComposeOfflineDomainJoin() to API.
   via  532701e3cce s3:libnetapi: Add NetComposeOfflineDomainJoin() 
boilerplate
   via  740e704bd68 s3:libnetapi: Add NetComposeOfflineDomainJoin() to IDL
   via  bdab834dfad s3:libnetapi: Add some comments to document ODJ blob 
charset conversions
   via  e4afb211fe3 s3:libnetapi: Return error from RequestOfflineJoin
   via  d3f3c40141d pidl/tests: Add tests for hang with nested struct.
   via  3f3fccab05d pidl/lib: Add recursion detection logic to prevent 
looping.
  from  171171565f1 .gitlab-ci: Do builds under /builds as this is never an 
overlayfs

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit f3c632e74ba100b455eeac66e8914b11d1d9b0a0
Author: Samuel Cabrero 
Date:   Mon Sep 4 16:49:52 2023 +0200

testprogs: Add net offlinejoin composeodj tests

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13577

Signed-off-by: Samuel Cabrero 
Reviewed-by: Andrew Bartlett 

Autobuild-User(master): Andrew Bartlett 
Autobuild-Date(master): Tue Sep  5 22:11:46 UTC 2023 on atb-devel-224

commit e92e4b9544231c15eaf0bdbba4505345cd0f6ab5
Author: Samuel Cabrero 
Date:   Mon Sep 4 16:18:35 2023 +0200

testprogs: Cleanup machine account in net offlinejoin tests

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13577

Signed-off-by: Samuel Cabrero 
Reviewed-by: Andrew Bartlett 

commit c14a4f51443f67bc46a670a342eed8cb9e81f37d
Author: Samuel Cabrero 
Date:   Wed Aug 30 20:53:18 2023 +0200

s3:net: Allow to load ODJ blob from stdin

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13577

Signed-off-by: Samuel Cabrero 
Reviewed-by: Andrew Bartlett 

commit b2399b6994c89404f245e1a97ba1c1cf13d7fc86
Author: Samuel Cabrero 
Date:   Wed Aug 30 20:25:17 2023 +0200

s3:net: Load ODJ blob from file only if "loadfile" parameter is present

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13577

Signed-off-by: Samuel Cabrero 
Reviewed-by: Andrew Bartlett 

commit 4a1f2071a6028a761bbe7efee20e9654851b51f0
Author: Samuel Cabrero 
Date:   Thu Aug 31 12:46:52 2023 +0200

s3:net: Add "net offlinejoin composeodj" command

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13577

Signed-off-by: Samuel Cabrero 
Reviewed-by: Andrew Bartlett 

commit a8bd8f22aac2c223e85e318dba7af8b64052b053
Author: Samuel Cabrero 
Date:   Thu Aug 31 12:45:42 2023 +0200

s3:libnetapi: Implement NetComposeOfflineDomainJoin_l()

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13577

Signed-off-by: Samuel Cabrero 
Reviewed-by: Andrew Bartlett 

commit 7cabbec2eaf5aefd3751c635c12556eca590f506
Author: Samuel Cabrero 
Date:   Thu Aug 31 12:44:26 2023 +0200

s3:libnetapi: Add NetComposeOfflineDomainJoin() to API.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13577

Signed-off-by: Samuel Cabrero 
Reviewed-by: Andrew Bartlett 

commit 532701e3cce9d15e95166ee7c24cd1e4af51fcc4
Author: Samuel Cabrero 
Date:   Thu Aug 31 12:43:22 2023 +0200

s3:libnetapi: Add NetComposeOfflineDomainJoin() boilerplate

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13577

Signed-off-by: Samuel Cabrero 
Reviewed-by: Andrew Bartlett 

commit 740e704bd68a6b618b62336ba1583c0edeb82d6f
Author: Samuel Cabrero 
Date:   Thu Aug 31 12:39:04 2023 +0200

s3:libnetapi: Add NetComposeOfflineDomainJoin() to IDL

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13577

Signed-off-by: Samuel Cabrero 
Reviewed-by: Andrew Bartlett 

commit bdab834dfad55776155915f7ec410b5a192406fa
Author: Samuel Cabrero 
Date:   Mon Sep 4 10:47:06 2023 +0200

s3:libnetapi: Add some comments to document ODJ blob charset conversions

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13577

Signed-off-by: Samuel Cabrero 
Reviewed-by: Andrew Bartlett 

commit e4afb211fe32f2aa92cc903df948874046f60305
Author: Samuel Cabrero 
Date:   Wed Aug 30 19:59:04 2023 +0200

s3:libnetapi: Return error from RequestOfflineJoin

The error code must be returned to caller even if the error string is not 
set.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13577

Signed-off-by: Samuel Cabrero 
Reviewed-by: Andrew Bartlett 

commit d3f3c40141d9d9da776f00cbb85b7f5203f6f1ab
Author: Noel 

[SCM] Samba Shared Repository - branch master updated

2023-09-05 Thread Stefan Metzmacher
The branch, master has been updated
   via  171171565f1 .gitlab-ci: Do builds under /builds as this is never an 
overlayfs
  from  0e244ff79b6 s3:torture: Remove masktest.c

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit 171171565f1909592cf728d3f6d78c611c6a30ed
Author: Andrew Bartlett 
Date:   Tue Sep 5 20:28:02 2023 +1200

.gitlab-ci: Do builds under /builds as this is never an overlayfs

On the GitLab shared runners / is overlayfs, which /builds being ext,
so we want this real filesystem, which should be faster in any case.

This may allow us to use GitLab shared runners for more jobs.

Signed-off-by: Andrew Bartlett 
Reviewed-by: Stefan Metzmacher 

Autobuild-User(master): Stefan Metzmacher 
Autobuild-Date(master): Tue Sep  5 14:20:48 UTC 2023 on atb-devel-224

---

Summary of changes:
 .gitlab-ci-main.yml | 54 ++---
 1 file changed, 27 insertions(+), 27 deletions(-)


Changeset truncated at 500 lines:

diff --git a/.gitlab-ci-main.yml b/.gitlab-ci-main.yml
index 729de8654bb..30c1980209f 100644
--- a/.gitlab-ci-main.yml
+++ b/.gitlab-ci-main.yml
@@ -170,7 +170,7 @@ include:
   script:
 # gitlab predefines CI_JOB_NAME for each job. The gitlab job usually 
matches the
 # autobuild name, which means we can define a default template that runs 
most autobuild jobs
-- script/autobuild.py $AUTOBUILD_JOB_NAME 
$SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE  --verbose --nocleanup --keeplogs --tail 
--full-testbase /tmp/samba-testbase
+- script/autobuild.py $AUTOBUILD_JOB_NAME 
$SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE  --verbose --nocleanup --keeplogs --tail 
--full-testbase /builds/samba-testbase
 
 # Ensure when adding a new job below that you also add it to
 # the dependencies for 'pages' below for the code coverage page
@@ -179,14 +179,14 @@ include:
 others:
   extends: .shared_template
   script:
-- script/autobuild.py ldb  $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase/ldb
-- script/autobuild.py pidl $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase/pidl
-- script/autobuild.py replace  $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/tmp/samba-testbase/replace
-- script/autobuild.py talloc   $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/tmp/samba-testbase/talloc
-- script/autobuild.py tdb  $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase/tdb
-- script/autobuild.py tevent   $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/tmp/samba-testbase/tevent
-- script/autobuild.py samba-xc $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/tmp/samba-testbase/samba-xc
-- script/autobuild.py docs-xml $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/tmp/samba-testbase/docs-xml
+- script/autobuild.py ldb  $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/builds/samba-testbase/ldb
+- script/autobuild.py pidl $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/builds/samba-testbase/pidl
+- script/autobuild.py replace  $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/builds/samba-testbase/replace
+- script/autobuild.py talloc   $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/builds/samba-testbase/talloc
+- script/autobuild.py tdb  $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/builds/samba-testbase/tdb
+- script/autobuild.py tevent   $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/builds/samba-testbase/tevent
+- script/autobuild.py samba-xc $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/builds/samba-testbase/samba-xc
+- script/autobuild.py docs-xml $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE 
--verbose --nocleanup --keeplogs --tail --full-testbase 
/builds/samba-testbase/docs-xml
 
 .shared_template_build_only:
   extends: .shared_template
@@ -203,20 +203,20 @@ others:
   script:
 # gitlab predefines CI_JOB_NAME for each job. The gitlab job usually 
matches the
 # autobuild name, which means we can define a default template that runs 
most autobuild jobs
-- script/autobuild.py $AUTOBUILD_JOB_NAME 
$SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE  --verbose 

[SCM] Samba Shared Repository - branch v4-17-test updated

2023-09-05 Thread Jule Anger
The branch, v4-17-test has been updated
   via  f8197d6509f mdssvc: better support for search with mdfind from Macs
  from  1361e545452 vfs_aio_pthread: use SMB_VFS_NEXT_OPENAT() in 
aio_pthread_openat_fn()

https://git.samba.org/?p=samba.git;a=shortlog;h=v4-17-test


- Log -
commit f8197d6509f166a809b53ad4ec623b628cf89285
Author: Ralph Boehme 
Date:   Tue Aug 29 16:14:38 2023 +0200

mdssvc: better support for search with mdfind from Macs

When searching Samba via Spotlight from a Mac with mdfind, only 50 results 
are
returned.

It seems the changes for bug #15342 where one step in the right
direction. There, a status indicator meaning "search is still being 
processed"
was implemented, returning a special status indicator (0x23) in a response, 
when
the query was still running in the backend, eg Elasticsearch, and we 
haven't got
any result when when the Mac already comes along asking for results of a 
query.

Turns out, we should also return 0x23, ie "search is still being processed" 
when
we have some initial search results from the backend. Otherwise mdfind will 
stop
querying for more results. It works in Finder, as the Finder by default 
employs
a "live" search where it just keeps polling for more results even after the
server returned an empty result set. The Finder just keeps on querying in 
some
interval, typically 4 seconds, and a Mac server Spotlight server might 
return
new results if new files where created that match the query, hence "live"
search.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=15463

Signed-off-by: Ralph Boehme 
Reviewed-by: Noel Power 

Autobuild-User(master): Ralph Böhme 
Autobuild-Date(master): Wed Aug 30 10:51:40 UTC 2023 on atb-devel-224

(cherry picked from commit 3afa27a01ca0b81b0044d5d543a36582e67a)

Autobuild-User(v4-17-test): Jule Anger 
Autobuild-Date(v4-17-test): Tue Sep  5 10:01:13 UTC 2023 on sn-devel-184

---

Summary of changes:
 source3/rpc_server/mdssvc/mdssvc.c | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/rpc_server/mdssvc/mdssvc.c 
b/source3/rpc_server/mdssvc/mdssvc.c
index a7d5d7afc02..5f0ec0289f2 100644
--- a/source3/rpc_server/mdssvc/mdssvc.c
+++ b/source3/rpc_server/mdssvc/mdssvc.c
@@ -313,11 +313,11 @@ static bool add_results(sl_array_t *array, struct 
sl_query *slq)
bool ok;
 
/*
-* Taken from a network trace against a macOS SMB Spotlight server. If
-* the first fetch-query-results has no results yet because the search
-* is still running, macOS returns 0x23, otherwise 0x0.
+* Taken from network traces against a macOS SMB Spotlight server: if
+* the search is not finished yet in the backend macOS returns 0x23,
+* otherwise 0x0.
 */
-   if (slq->state >= SLQ_STATE_RESULTS ) {
+   if (slq->state >= SLQ_STATE_DONE) {
status = 0;
} else {
status = 0x23;


-- 
Samba Shared Repository



[SCM] Samba Shared Repository - branch v4-19-test updated

2023-09-05 Thread Jule Anger
The branch, v4-19-test has been updated
   via  eadd7e5f9bb mdssvc: better support for search with mdfind from Macs
  from  a8c5fe34b63 VERSION: Bump version up to Samba 4.19.1...

https://git.samba.org/?p=samba.git;a=shortlog;h=v4-19-test


- Log -
commit eadd7e5f9bbe6b52e1690a37e0f1c98954e14643
Author: Ralph Boehme 
Date:   Tue Aug 29 16:14:38 2023 +0200

mdssvc: better support for search with mdfind from Macs

When searching Samba via Spotlight from a Mac with mdfind, only 50 results 
are
returned.

It seems the changes for bug #15342 where one step in the right
direction. There, a status indicator meaning "search is still being 
processed"
was implemented, returning a special status indicator (0x23) in a response, 
when
the query was still running in the backend, eg Elasticsearch, and we 
haven't got
any result when when the Mac already comes along asking for results of a 
query.

Turns out, we should also return 0x23, ie "search is still being processed" 
when
we have some initial search results from the backend. Otherwise mdfind will 
stop
querying for more results. It works in Finder, as the Finder by default 
employs
a "live" search where it just keeps polling for more results even after the
server returned an empty result set. The Finder just keeps on querying in 
some
interval, typically 4 seconds, and a Mac server Spotlight server might 
return
new results if new files where created that match the query, hence "live"
search.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=15463

Signed-off-by: Ralph Boehme 
Reviewed-by: Noel Power 

Autobuild-User(master): Ralph Böhme 
Autobuild-Date(master): Wed Aug 30 10:51:40 UTC 2023 on atb-devel-224

(cherry picked from commit 3afa27a01ca0b81b0044d5d543a36582e67a)

Autobuild-User(v4-19-test): Jule Anger 
Autobuild-Date(v4-19-test): Tue Sep  5 09:33:17 UTC 2023 on atb-devel-224

---

Summary of changes:
 source3/rpc_server/mdssvc/mdssvc.c | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/rpc_server/mdssvc/mdssvc.c 
b/source3/rpc_server/mdssvc/mdssvc.c
index abeaac8263c..c34babb2525 100644
--- a/source3/rpc_server/mdssvc/mdssvc.c
+++ b/source3/rpc_server/mdssvc/mdssvc.c
@@ -313,11 +313,11 @@ static bool add_results(sl_array_t *array, struct 
sl_query *slq)
bool ok;
 
/*
-* Taken from a network trace against a macOS SMB Spotlight server. If
-* the first fetch-query-results has no results yet because the search
-* is still running, macOS returns 0x23, otherwise 0x0.
+* Taken from network traces against a macOS SMB Spotlight server: if
+* the search is not finished yet in the backend macOS returns 0x23,
+* otherwise 0x0.
 */
-   if (slq->state >= SLQ_STATE_RESULTS ) {
+   if (slq->state >= SLQ_STATE_DONE) {
status = 0;
} else {
status = 0x23;


-- 
Samba Shared Repository



[SCM] Samba Shared Repository - branch v4-18-test updated

2023-09-05 Thread Jule Anger
The branch, v4-18-test has been updated
   via  69fd70b83df mdssvc: better support for search with mdfind from Macs
  from  14380eb832d vfs_aio_pthread: use SMB_VFS_NEXT_OPENAT() in 
aio_pthread_openat_fn()

https://git.samba.org/?p=samba.git;a=shortlog;h=v4-18-test


- Log -
commit 69fd70b83df5f6a77192f6eeb3f333fb2a26643a
Author: Ralph Boehme 
Date:   Tue Aug 29 16:14:38 2023 +0200

mdssvc: better support for search with mdfind from Macs

When searching Samba via Spotlight from a Mac with mdfind, only 50 results 
are
returned.

It seems the changes for bug #15342 where one step in the right
direction. There, a status indicator meaning "search is still being 
processed"
was implemented, returning a special status indicator (0x23) in a response, 
when
the query was still running in the backend, eg Elasticsearch, and we 
haven't got
any result when when the Mac already comes along asking for results of a 
query.

Turns out, we should also return 0x23, ie "search is still being processed" 
when
we have some initial search results from the backend. Otherwise mdfind will 
stop
querying for more results. It works in Finder, as the Finder by default 
employs
a "live" search where it just keeps polling for more results even after the
server returned an empty result set. The Finder just keeps on querying in 
some
interval, typically 4 seconds, and a Mac server Spotlight server might 
return
new results if new files where created that match the query, hence "live"
search.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=15463

Signed-off-by: Ralph Boehme 
Reviewed-by: Noel Power 

Autobuild-User(master): Ralph Böhme 
Autobuild-Date(master): Wed Aug 30 10:51:40 UTC 2023 on atb-devel-224

(cherry picked from commit 3afa27a01ca0b81b0044d5d543a36582e67a)

Autobuild-User(v4-18-test): Jule Anger 
Autobuild-Date(v4-18-test): Tue Sep  5 09:28:33 UTC 2023 on atb-devel-224

---

Summary of changes:
 source3/rpc_server/mdssvc/mdssvc.c | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/rpc_server/mdssvc/mdssvc.c 
b/source3/rpc_server/mdssvc/mdssvc.c
index a7d5d7afc02..5f0ec0289f2 100644
--- a/source3/rpc_server/mdssvc/mdssvc.c
+++ b/source3/rpc_server/mdssvc/mdssvc.c
@@ -313,11 +313,11 @@ static bool add_results(sl_array_t *array, struct 
sl_query *slq)
bool ok;
 
/*
-* Taken from a network trace against a macOS SMB Spotlight server. If
-* the first fetch-query-results has no results yet because the search
-* is still running, macOS returns 0x23, otherwise 0x0.
+* Taken from network traces against a macOS SMB Spotlight server: if
+* the search is not finished yet in the backend macOS returns 0x23,
+* otherwise 0x0.
 */
-   if (slq->state >= SLQ_STATE_RESULTS ) {
+   if (slq->state >= SLQ_STATE_DONE) {
status = 0;
} else {
status = 0x23;


-- 
Samba Shared Repository



[SCM] Samba Shared Repository - branch master updated

2023-09-05 Thread Andreas Schneider
The branch, master has been updated
   via  0e244ff79b6 s3:torture: Remove masktest.c
  from  3fbc514a2c3 docs:smbdotconf: Inform that changing 'winbind max 
domain connections' needs a restart

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit 0e244ff79b6d481ac995411070f83471b2e6ac40
Author: Andreas Schneider 
Date:   Mon Sep 4 16:49:39 2023 +0200

s3:torture: Remove masktest.c

The file is not built.

Signed-off-by: Andreas Schneider 
Reviewed-by: Andrew Bartlett 

Autobuild-User(master): Andreas Schneider 
Autobuild-Date(master): Tue Sep  5 07:30:12 UTC 2023 on atb-devel-224

---

Summary of changes:
 source3/torture/masktest.c | 581 -
 1 file changed, 581 deletions(-)
 delete mode 100644 source3/torture/masktest.c


Changeset truncated at 500 lines:

diff --git a/source3/torture/masktest.c b/source3/torture/masktest.c
deleted file mode 100644
index d7485cfb5eb..000
--- a/source3/torture/masktest.c
+++ /dev/null
@@ -1,581 +0,0 @@
-/* 
-   Unix SMB/CIFS implementation.
-   mask_match tester
-   Copyright (C) Andrew Tridgell 1999
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 3 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program.  If not, see .
-*/
-
-#include "includes.h"
-#include "system/filesys.h"
-#include "trans2.h"
-#include "libsmb/libsmb.h"
-#include "libsmb/nmblib.h"
-#include "../libcli/smb/smbXcli_base.h"
-#include "lib/util/string_wrappers.h"
-
-static fstring password;
-static fstring username;
-static int got_pass;
-static struct cli_credentials *test_creds;
-static int max_protocol = -1;
-static bool showall = False;
-static bool old_list = False;
-static const char *maskchars = "<>\"?*abc.";
-static const char *filechars = "abcdefghijklm.";
-static int verbose;
-static int die_on_error;
-static int NumLoops = 0;
-static int ignore_dot_errors = 0;
-
-extern char *optarg;
-extern int optind;
-
-/* a test fn for LANMAN mask support */
-static int ms_fnmatch_lanman_core(const char *pattern, const char *string)
-{
-   const char *p = pattern, *n = string;
-   char c;
-
-   if (strcmp(p,"?")==0 && strcmp(n,".")==0) goto match;
-
-   while ((c = *p++)) {
-   switch (c) {
-   case '.':
-   /* if (! *n && ! *p) goto match; */
-   if (*n != '.') goto nomatch;
-   n++;
-   break;
-
-   case '?':
-   if ((*n == '.' && n[1] != '.') || ! *n) goto next;
-   n++;
-   break;
-
-   case '>':
-   if (n[0] == '.') {
-   if (! n[1] && ms_fnmatch_lanman_core(p, n+1) == 
0) goto match;
-   if (ms_fnmatch_lanman_core(p, n) == 0) goto 
match;
-   goto nomatch;
-   }
-   if (! *n) goto next;
-   n++;
-   break;
-
-   case '*':
-   if (! *p) goto match;
-   for (; *n; n++) {
-   if (ms_fnmatch_lanman_core(p, n) == 0) goto 
match;
-   }
-   break;
-
-   case '<':
-   for (; *n; n++) {
-   if (ms_fnmatch_lanman_core(p, n) == 0) goto 
match;
-   if (*n == '.' && !strchr_m(n+1,'.')) {
-   n++;
-   break;
-   }
-   }
-   break;
-
-   case '"':
-   if (*n == 0 && ms_fnmatch_lanman_core(p, n) == 0) goto 
match;
-   if (*n != '.') goto nomatch;
-   n++;
-   break;
-
-   default:
-   if (c != *n) goto nomatch;
-   n++;
-   }
-   }
-
-   if (! *n) goto match;
-
- nomatch:
-   if (verbose) printf("NOMATCH pattern=[%s] string=[%s]\n", pattern, 
string);
-   return -1;
-
-next:
-   if (ms_fnmatch_lanman_core(p, n) == 0) goto match;
-goto nomatch;
-
-