X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=lib%2Fgetsockopt.c;h=4e53a6fe999656bc2541c14b2f2447f7df975945;hb=11b16d3cdc4646f80822751dc6882b21c9da2a22;hp=128edd6df893e09c8216adb0f46e468997a88a0b;hpb=6aebe8304ac5fcc50de5042107fada53612d552e;p=gnulib.git diff --git a/lib/getsockopt.c b/lib/getsockopt.c index 128edd6df..4e53a6fe9 100644 --- a/lib/getsockopt.c +++ b/lib/getsockopt.c @@ -1,6 +1,6 @@ /* getsockopt.c --- wrappers for Windows getsockopt function - Copyright (C) 2008-2009 Free Software Foundation, Inc. + Copyright (C) 2008-2010 Free Software Foundation, Inc. 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 @@ -51,7 +51,7 @@ rpl_getsockopt (int fd, int level, int optname, void *optval, socklen_t *optlen) tv.tv_usec = (milliseconds - 1000 * tv.tv_sec) * 1000; n = sizeof (struct timeval); if (n > *optlen) - n = *optlen; + n = *optlen; memcpy (optval, &tv, n); *optlen = n; }