chat.c (9e522f7a18a64d3b9ea901ed70d0eee78342f0c6) chat.c (b92f6bd2b8c8170b81fb62bb79e0ba010ddb8f5a)
1/*-
2 * Copyright (c) 1997
3 * David L Nugent <davidn@blaze.net.au>.
4 * All rights reserved.
5 *
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, is permitted provided that the following conditions

--- 8 unchanged lines hidden (view full) ---

17 * is permitted provided this notation is included.
18 * 4. Absolutely no warranty of function or purpose is made by the authors.
19 * 5. Modifications may be freely made to this file providing the above
20 * conditions are met.
21 *
22 * Modem chat module - send/expect style functions for getty
23 * For semi-intelligent modem handling.
24 *
1/*-
2 * Copyright (c) 1997
3 * David L Nugent <davidn@blaze.net.au>.
4 * All rights reserved.
5 *
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, is permitted provided that the following conditions

--- 8 unchanged lines hidden (view full) ---

17 * is permitted provided this notation is included.
18 * 4. Absolutely no warranty of function or purpose is made by the authors.
19 * 5. Modifications may be freely made to this file providing the above
20 * conditions are met.
21 *
22 * Modem chat module - send/expect style functions for getty
23 * For semi-intelligent modem handling.
24 *
25 * $Id$
25 * $Id: chat.c,v 1.3 1997/02/22 14:21:36 peter Exp $
26 */
27
28#include <sys/param.h>
29#include <sys/stat.h>
30#include <sys/ioctl.h>
31#include <sys/resource.h>
32#include <sys/ttydefaults.h>
33#include <sys/utsname.h>

--- 184 unchanged lines hidden (view full) ---

218 *r++ = *q;
219 break;
220 case 0: /* not past eos */
221 --q;
222 break;
223 }
224 } else {
225 /* copy standard character */
26 */
27
28#include <sys/param.h>
29#include <sys/stat.h>
30#include <sys/ioctl.h>
31#include <sys/resource.h>
32#include <sys/ttydefaults.h>
33#include <sys/utsname.h>

--- 184 unchanged lines hidden (view full) ---

218 *r++ = *q;
219 break;
220 case 0: /* not past eos */
221 --q;
222 break;
223 }
224 } else {
225 /* copy standard character */
226 *r++ == *q;
226 *r++ = *q;
227 }
228 }
229
230 /* Remove surrounding quotes, if any
231 */
232 if (*p == '"' || *p == '\'') {
233 q = strrchr(p+1, *p);
234 if (q != NULL && *q == *p && q[1] == '\0') {

--- 281 unchanged lines hidden ---
227 }
228 }
229
230 /* Remove surrounding quotes, if any
231 */
232 if (*p == '"' || *p == '\'') {
233 q = strrchr(p+1, *p);
234 if (q != NULL && *q == *p && q[1] == '\0') {

--- 281 unchanged lines hidden ---