From 5ed44d5d2616c186ce12193eaa49f61ebf0f323f Mon Sep 17 00:00:00 2001 From: zacheiss Date: Fri, 29 Aug 2008 16:54:04 +0000 Subject: [PATCH] If someone has an exchange pobox, check if their imap filesystem exists and put that server in hesiod. --- gen/hesiod.pc | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/gen/hesiod.pc b/gen/hesiod.pc index 3b995581..317b0a26 100644 --- a/gen/hesiod.pc +++ b/gen/hesiod.pc @@ -270,7 +270,15 @@ int do_passwd(void) } if (eid != 0) - pid = eid; + { + /* Check for IMAP. Can't use iid because it should be zero. */ + EXEC SQL SELECT mach_id INTO :mid FROM filesys + WHERE label = :login || '.po' AND type = 'IMAP'; + if (sqlca.sqlcode == 0) + pid = mid; + else + pid = eid; + } if (iid != 0) { -- 2.45.2