aboutsummaryrefslogtreecommitdiffstats
path: root/camel/camel-mime-utils.c
diff options
context:
space:
mode:
authorDan Winship <danw@src.gnome.org>2001-03-17 01:17:30 +0800
committerDan Winship <danw@src.gnome.org>2001-03-17 01:17:30 +0800
commit2eda2f02efaf475fd07ae6f43ed9ae7d35ecc429 (patch)
treeea80b847b01ec012e79bd864b039d336430047d9 /camel/camel-mime-utils.c
parent7b003b963ea92526980475abfb9b61673b232ccc (diff)
downloadgsoc2013-evolution-2eda2f02efaf475fd07ae6f43ed9ae7d35ecc429.tar
gsoc2013-evolution-2eda2f02efaf475fd07ae6f43ed9ae7d35ecc429.tar.gz
gsoc2013-evolution-2eda2f02efaf475fd07ae6f43ed9ae7d35ecc429.tar.bz2
gsoc2013-evolution-2eda2f02efaf475fd07ae6f43ed9ae7d35ecc429.tar.lz
gsoc2013-evolution-2eda2f02efaf475fd07ae6f43ed9ae7d35ecc429.tar.xz
gsoc2013-evolution-2eda2f02efaf475fd07ae6f43ed9ae7d35ecc429.tar.zst
gsoc2013-evolution-2eda2f02efaf475fd07ae6f43ed9ae7d35ecc429.zip
Don't use getdomainname: it's NIS crap, not DNS.
* camel-mime-utils.c (header_msgid_generate): Don't use getdomainname: it's NIS crap, not DNS. svn path=/trunk/; revision=8761
Diffstat (limited to 'camel/camel-mime-utils.c')
-rw-r--r--camel/camel-mime-utils.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/camel/camel-mime-utils.c b/camel/camel-mime-utils.c
index b2abb59ef4..edec357160 100644
--- a/camel/camel-mime-utils.c
+++ b/camel/camel-mime-utils.c
@@ -2935,7 +2935,7 @@ header_raw_clear(struct _header_raw **list)
char *
header_msgid_generate (void)
{
- char host[MAXHOSTNAMELEN], domain[MAXHOSTNAMELEN];
+ char host[MAXHOSTNAMELEN];
#ifdef ENABLE_THREADS
static pthread_mutex_t count_lock = PTHREAD_MUTEX_INITIALIZER;
#define COUNT_LOCK() pthread_mutex_lock (&count_lock)
@@ -2945,16 +2945,14 @@ header_msgid_generate (void)
#define COUNT_UNLOCK()
#endif /* ENABLE_THREADS */
static gint count = 0;
- gint hrv, drv;
+ gint hrv;
char *ret;
hrv = gethostname (host, sizeof (host));
- drv = getdomainname (domain, sizeof (domain));
COUNT_LOCK ();
- ret = g_strdup_printf ("%d.%d.%d.camel@%s.%s", (gint) time (NULL), getpid (), count++,
- (hrv == 0 && host && *host) ? host : "unknown.host",
- (drv && domain && *domain) ? domain : "unknown.domain");
+ ret = g_strdup_printf ("%d.%d.%d.camel@%s", (gint) time (NULL), getpid (), count++,
+ (hrv == 0 && host && *host) ? host : "unknown.host");
COUNT_UNLOCK ();
return ret;