]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
samba-tool domain: improve error message when `patch` fails
authorDouglas Bagnall <douglas.bagnall@catalyst.net.nz>
Thu, 20 May 2021 23:41:37 +0000 (11:41 +1200)
committerJeremy Allison <jra@samba.org>
Thu, 10 Jun 2021 00:29:32 +0000 (00:29 +0000)
The old message confused even the wisest among us:

https://lists.samba.org/archive/samba/2021-May/236021.html

and while /user/bin/patch might be overly specific, it should point
people in the right direction.

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Jeremy Allison <jra@samba.org>
python/samba/netcmd/domain.py

index 6b1e3ba3f7ee761bdaea655e0255416322810816..91c82297e26ede2c0bd91017bfce61262b96287d 100644 (file)
@@ -4182,7 +4182,8 @@ class cmd_domain_schema_upgrade(Command):
                                              stderr=subprocess.PIPE, cwd=temp_folder)
                     except (OSError, IOError):
                         shutil.rmtree(temp_folder)
-                        raise CommandError("Failed to upgrade schema. Check if 'patch' is installed.")
+                        raise CommandError("Failed to upgrade schema. "
+                                           "Is '/usr/bin/patch' missing?")
 
                     stdout, stderr = p.communicate()