/mandos/trunk

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/trunk

« back to all changes in this revision

Viewing changes to plugins.d/passprompt.c

  • Committer: Björn Påhlsson
  • Date: 2008-07-21 23:17:19 UTC
  • mfrom: (22 mandos)
  • mto: This revision was merged to the branch mainline in revision 23.
  • Revision ID: belorn@braxen-20080721231719-6ddpx0w2s2gkeaea
merge

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*  -*- coding: utf-8 -*- */
 
2
/*
 
3
 * Passprompt - Read a password from the terminal and print it
 
4
 *
 
5
 * Copyright © 2007-2008 Teddy Hogeborn and Björn Påhlsson.
 
6
 * 
 
7
 * This program is free software: you can redistribute it and/or
 
8
 * modify it under the terms of the GNU General Public License as
 
9
 * published by the Free Software Foundation, either version 3 of the
 
10
 * License, or (at your option) any later version.
 
11
 * 
 
12
 * This program is distributed in the hope that it will be useful, but
 
13
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 
14
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
15
 * General Public License for more details.
 
16
 * 
 
17
 * You should have received a copy of the GNU General Public License
 
18
 * along with this program.  If not, see
 
19
 * <http://www.gnu.org/licenses/>.
 
20
 * 
 
21
 * Contact the authors at <https://www.fukt.bsnet.se/~belorn/> and
 
22
 * <https://www.fukt.bsnet.se/~teddy/>.
 
23
 */
 
24
 
1
25
#define _GNU_SOURCE             /* getline() */
2
26
#define _FORTIFY_SOURCE 2
 
27
 
3
28
#include <termios.h>            /* struct termios, tcsetattr(),
4
29
                                   TCSAFLUSH, tcgetattr(), ECHO */
5
30
#include <unistd.h>             /* struct termios, tcsetattr(),
25
50
volatile bool quit_now = false;
26
51
bool debug = false;
27
52
 
28
 
void termination_handler(int signum){
 
53
void termination_handler(__attribute__((unused))int signum){
29
54
  quit_now = true;
30
55
}
31
56