summaryrefslogtreecommitdiff
path: root/comms/hylafax/patches/patch-ao
blob: b8d940f56d2b96dfb6f3872ea31cad91b3d93761 (plain)
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
$NetBSD: patch-ao,v 1.7 2005/01/27 16:22:37 adam Exp $

--- hfaxd/User.c++.orig	2005-01-10 04:52:09.000000000 +0000
+++ hfaxd/User.c++
@@ -244,7 +244,7 @@ HylaFAXServer::userName(u_int id)
     if (id == uid)				// user currently logged in
 	return (const char*) the_user;
     if (id == FAXUID_ANON)			// anonymous user
-	return "fax";
+	return FAX_USER;
     if (idcache == NULL)			// load cache from file
 	fillIDCache();
     const fxStr* hit = idcache->find(id);	// check cache
@@ -263,7 +263,7 @@ HylaFAXServer::userID(const char* name, 
 {
     if (name == the_user)
 	id = uid;
-    else if (strcmp(name, "fax") == 0)
+    else if (strcmp(name, FAX_USER) == 0)
 	id = FAXUID_ANON;
     else {
 	if (idcache == NULL)
@@ -350,7 +350,7 @@ HylaFAXServer::findUser(FILE* db, const 
     if (faxuid < FAXUID_MAX)
 	SetBit(FAXUID_RESV);			// reserved uid
     else
-	logError("Internal error, \"fax\" UID (%u) too large.", faxuid);
+	logError("Internal error, \"" FAX_USER "\" UID (%u) too large.", faxuid);
     SetBit(FAXUID_ANON);			// anonymous uid is reserved
     while (nextRecord(db, line, sizeof (line))) {
 	if (line[0] == '!')