~ubuntu-branches/ubuntu/precise/openvpn/precise-updates

« back to all changes in this revision

Viewing changes to forward.c

  • Committer: Bazaar Package Importer
  • Author(s): Chuck Short
  • Date: 2010-10-05 06:21:14 UTC
  • mfrom: (1.1.16 upstream) (10.2.8 sid)
  • Revision ID: james.westby@ubuntu.com-20101005062114-18lyqud9e3p4g735
Tags: 2.1.3-1ubuntu1
* Merge from debian unstable.  Remaining changes:
  + debian/openvpn.init.d:
    - Do not use start-stop-daemon and </dev/null to avoid blocking boot.
    - Show per-VPN result messages.
    - Add "--script-security 2" by default for backwards compatablitiy
  + debian/control: Add lsb-base >= 3.2-14 to allow status_of_proc()

Show diffs side-by-side

added added

removed removed

Lines of Context:
5
5
 *             packet encryption, packet authentication, and
6
6
 *             packet compression.
7
7
 *
8
 
 *  Copyright (C) 2002-2009 OpenVPN Technologies, Inc. <sales@openvpn.net>
 
8
 *  Copyright (C) 2002-2010 OpenVPN Technologies, Inc. <sales@openvpn.net>
9
9
 *
10
10
 *  This program is free software; you can redistribute it and/or modify
11
11
 *  it under the terms of the GNU General Public License version 2
687
687
        if (c->options.inetd)
688
688
          {
689
689
            c->sig->signal_received = SIGTERM;
 
690
            c->sig->signal_text = "connection-reset-inetd";
690
691
            msg (D_STREAM_ERRORS, "Connection reset, inetd/xinetd exit [%d]", status);
691
692
          }
692
693
        else
693
694
          {
694
 
            c->sig->signal_received = SIGUSR1; /* SOFT-SIGUSR1 -- TCP connection reset */
695
 
            msg (D_STREAM_ERRORS, "Connection reset, restarting [%d]", status);
 
695
#ifdef ENABLE_OCC
 
696
            if (event_timeout_defined(&c->c2.explicit_exit_notification_interval))
 
697
              {
 
698
                msg (D_STREAM_ERRORS, "Connection reset during exit notification period, ignoring [%d]", status);
 
699
                openvpn_sleep(1);
 
700
              }
 
701
            else
 
702
#endif
 
703
              {
 
704
                c->sig->signal_received = SIGUSR1; /* SOFT-SIGUSR1 -- TCP connection reset */
 
705
                c->sig->signal_text = "connection-reset";
 
706
                msg (D_STREAM_ERRORS, "Connection reset, restarting [%d]", status);
 
707
              }
696
708
          }
697
 
        c->sig->signal_text = "connection-reset";
698
709
      }
699
710
      perf_pop ();
700
711
      return;