[PATCH] Fix 'net ads changetrustpw'
Rowland Penny
rpenny at samba.org
Thu Aug 10 08:20:41 UTC 2017
On Thu, 10 Aug 2017 09:30:26 +0200
Andreas Schneider <asn at samba.org> wrote:
> On Wednesday, 9 August 2017 19:03:34 CEST Rowland Penny via
> samba-technical wrote:
> > On Wed, 09 Aug 2017 18:45:10 +0200
> > Andreas Schneider via samba-technical
> > <samba-technical at lists.samba.org>
> >
> > wrote:
> > > Hi,
> > >
> > > as always, untested code is broken code. So I broke 'net ads
> > > changetrustpw' in Samba 4.6.
> > >
> > > The attached patch fixes the issue and adds a tests which verifies
> > > that it is working.
> > >
> > >
> > > Please review and push if OK.
> > >
> > >
> > > Thanks,
> > >
> > > Andreas
> >
> > OK, I asked Andrew this and got a very non committal answer, so this
> > seems to a good place to ask everyone, why does Samba use the
> > ancient backticks ?
> >
> > i.e `expr $failed + 1` instead of $((failed + 1))
>
> I normally use $() but as this is copy and paste it is using the old
> way. On newer scripts you can see $() in my scripts at least.
>
> If you want to can start changing it in all scripts :-)
>
>
> Andreas
>
Yes, but where do I stop ?
Have you ever run any of the test sh scripts through shellcheck ?
It also sort of backs up up what Andrew has been saying lately, people
will just cut and paste bad code.
It wouldn't be allowed in a python, so why in sh ?
Rowland
More information about the samba-technical
mailing list