1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
diff -uNr -r postfix-2.5.1-orig/src/sendmail/sendmail.c postfix-2.5.1/src/sendmail/sendmail.c
--- postfix-2.5.1-orig/src/sendmail/sendmail.c 2008-01-09 14:59:40.000000000 +0100
+++ postfix-2.5.1/src/sendmail/sendmail.c 2008-03-14 19:23:25.405275019 +0100
@@ -1046,7 +1046,7 @@
mode = SM_MODE_MAILQ;
} else if (strcmp(argv[0], "newaliases") == 0) {
mode = SM_MODE_NEWALIAS;
- } else if (strcmp(argv[0], "smtpd") == 0) {
+ } else if (strncmp(argv[0], "smtpd", 5) == 0) {
mode = SM_MODE_DAEMON;
} else {
mode = SM_MODE_ENQUEUE;
diff -uNr -r postfix-2.5.1-orig/src/smtp/smtp.c postfix-2.5.1/src/smtp/smtp.c
--- postfix-2.5.1-orig/src/smtp/smtp.c 2008-01-15 01:41:46.000000000 +0100
+++ postfix-2.5.1/src/smtp/smtp.c 2008-03-14 19:23:25.405275019 +0100
@@ -962,7 +962,7 @@
TLS_CLIENT_INIT(&props,
log_level = var_smtp_tls_loglevel,
verifydepth = var_smtp_tls_scert_vd,
- cache_type = strcmp(var_procname, "smtp") == 0 ?
+ cache_type = strncmp(var_procname, "smtp", 4) == 0 ?
TLS_MGR_SCACHE_SMTP : TLS_MGR_SCACHE_LMTP,
cert_file = var_smtp_tls_cert_file,
key_file = var_smtp_tls_key_file,
@@ -1058,7 +1058,7 @@
/*
* XXX At this point, var_procname etc. are not initialized.
*/
- smtp_mode = (strcmp(sane_basename((VSTRING *) 0, argv[0]), "smtp") == 0);
+ smtp_mode = (strncmp(sane_basename((VSTRING *) 0, argv[0]), "smtp", 4) == 0);
/*
* Initialize with the LMTP or SMTP parameter name space.
diff -uNr -r postfix-2.5.1-orig/src/smtp/smtp_state.c postfix-2.5.1/src/smtp/smtp_state.c
--- postfix-2.5.1-orig/src/smtp/smtp_state.c 2006-01-06 01:07:36.000000000 +0100
+++ postfix-2.5.1/src/smtp/smtp_state.c 2008-03-14 19:23:44.896995323 +0100
@@ -86,9 +86,9 @@
* form, and then to transform from the internal form to external forms Y
* and Z.
*/
- if (strcmp(var_procname, "lmtp") == 0) {
+ if (strncmp(var_procname, "lmtp", 4) == 0) {
state->misc_flags |= SMTP_MISC_FLAG_USE_LMTP;
- } else if (strcmp(var_procname, "smtp") == 0) {
+ } else if (strncmp(var_procname, "smtp", 4) == 0) {
/* void */
} else {
msg_fatal("unexpected process name \"%s\" - "
|