[openssh-commits] [openssh] 01/01: Make DEF_WEAK more likely to be correct.

git+noreply at mindrot.org git+noreply at mindrot.org
Tue Oct 8 14:48:53 AEDT 2019


This is an automated email from the git hooks/post-receive script.

dtucker pushed a commit to branch master
in repository openssh.

commit 0c7f8d2326d812b371f7afd63aff846973ec80a4
Author: Darren Tucker <dtucker at dtucker.net>
Date:   Tue Oct 8 14:44:50 2019 +1100

    Make DEF_WEAK more likely to be correct.
    
    Completely nop-ing out DEF_WEAK leaves an empty statemment which some
    compilers don't like.  Replace with a no-op function template.  ok djm@
---
 defines.h | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/defines.h b/defines.h
index e37e1647..7855fbf9 100644
--- a/defines.h
+++ b/defines.h
@@ -839,9 +839,10 @@ struct winsize {
 /*
  * We want functions in openbsd-compat, if enabled, to override system ones.
  * We no-op out the weak symbol definition rather than remove it to reduce
- * future sync problems.
+ * future sync problems.  Some compilers (eg Unixware) do not allow an
+ * empty statement, so we use a bogus function declaration.
  */
-#define DEF_WEAK(x)
+#define DEF_WEAK(x)	void __ssh_compat_weak_##x(void)
 
 /*
  * Platforms that have arc4random_uniform() and not arc4random_stir()

-- 
To stop receiving notification emails like this one, please contact
djm at mindrot.org.


More information about the openssh-commits mailing list