|
|
@ -2,7 +2,7 @@ |
|
|
|
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|
|
|
# |
|
|
|
# Filename: package/.../dropbear/legacy_sus.patch |
|
|
|
# Copyright (C) 2010 The OpenSDE Project |
|
|
|
# Copyright (C) 2010 - 2011 The OpenSDE Project |
|
|
|
# |
|
|
|
# More information can be found in the files COPYING and README. |
|
|
|
# |
|
|
@ -17,15 +17,20 @@ |
|
|
|
usleep() was deprecated by SUSv3 and newer LIBCs are starting to enforce that |
|
|
|
deprecation. |
|
|
|
|
|
|
|
--- ./svr-auth.c.orig 2010-09-20 16:12:52.000000000 -0400
|
|
|
|
+++ ./svr-auth.c 2010-09-20 16:15:08.000000000 -0400
|
|
|
|
@@ -337,7 +337,8 @@
|
|
|
|
--- ./svr-auth.c.orig 2011-04-29 16:58:36.000000000 +0200
|
|
|
|
+++ ./svr-auth.c 2011-04-29 17:01:48.000000000 +0200
|
|
|
|
@@ -338,11 +338,12 @@
|
|
|
|
encrypt_packet(); |
|
|
|
|
|
|
|
if (incrfail) { |
|
|
|
- usleep(300000); /* XXX improve this */
|
|
|
|
+ const struct timespec ts = { 0, 300000000L };
|
|
|
|
+ nanosleep(&ts, NULL); /* XXX improve this */
|
|
|
|
+ struct timespec ts = {0, 250000000L};
|
|
|
|
unsigned int delay; |
|
|
|
genrandom((unsigned char*)&delay, sizeof(delay)); |
|
|
|
/* We delay for 300ms +- 50ms, 0.1ms granularity */ |
|
|
|
- delay = 250000 + (delay % 1000)*100;
|
|
|
|
- usleep(delay);
|
|
|
|
+ ts.tv_nsec += (delay % 1000)*100000L;
|
|
|
|
+ nanosleep(&ts, NULL);
|
|
|
|
ses.authstate.failcount++; |
|
|
|
} |
|
|
|
|