~ubuntu-branches/ubuntu/trusty/gnutls26/trusty-security

« back to all changes in this revision

Viewing changes to gl/setsockopt.c

  • Committer: Bazaar Package Importer
  • Author(s): Andreas Metzler
  • Date: 2010-04-22 19:29:52 UTC
  • mto: (12.4.3 experimental) (1.5.1)
  • mto: This revision was merged to the branch mainline in revision 26.
  • Revision ID: james.westby@ubuntu.com-20100422192952-gbj6cvaan8e4ejck
Tags: upstream-2.9.10
ImportĀ upstreamĀ versionĀ 2.9.10

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* setsockopt.c --- wrappers for Windows setsockopt function
2
2
 
3
 
   Copyright (C) 2008-2009 Free Software Foundation, Inc.
 
3
   Copyright (C) 2008-2010 Free Software Foundation, Inc.
4
4
 
5
5
   This program is free software: you can redistribute it and/or modify
6
6
   it under the terms of the GNU General Public License as published by
41
41
    {
42
42
      const struct timeval *tv = optval;
43
43
      int milliseconds = tv->tv_sec * 1000 + tv->tv_usec / 1000;
44
 
      r = setsockopt (sock, level, optname, &milliseconds, sizeof (int));
 
44
      optval = &milliseconds;
 
45
      r = setsockopt (sock, level, optname, optval, sizeof (int));
45
46
    }
46
47
  else
47
48
    {