From 4d7a2ed5af5d8323e9c08ecb32c67b3c04d36a9a Mon Sep 17 00:00:00 2001
From: Ben Pfaff <blp@gnu.org>
Date: Tue, 9 Feb 2010 19:23:40 -0800
Subject: [PATCH] odt: Remove dependency on <pwd.h> because mingw32 does not
 have it.

The "meta:initial-creator" and "meta:creator" fields do not seem to me to
be important enough to have to deal with this dependency.

Reported by unknown-1 <pspp@sjpaes.nl>.
---
 src/output/odt.c | 11 -----------
 1 file changed, 11 deletions(-)

diff --git a/src/output/odt.c b/src/output/odt.c
index bfc698e79a..66e986be71 100644
--- a/src/output/odt.c
+++ b/src/output/odt.c
@@ -21,7 +21,6 @@
 #include <errno.h>
 #include <libgen.h>
 #include <libxml/xmlwriter.h>
-#include <pwd.h>
 #include <sys/stat.h>
 #include <sys/types.h>
 #include <time.h>
@@ -255,25 +254,15 @@ write_meta_data (struct odt_driver *odt)
 
   {
     char buf[30];
-    struct passwd *pw = getpwuid (getuid ());
     time_t t = time (NULL);
     struct tm *tm =  localtime (&t);
 
     strftime (buf, 30, "%Y-%m-%dT%H:%M:%S", tm);
 
-    xmlTextWriterStartElement (w, _xml ("meta:initial-creator"));
-    xmlTextWriterWriteString (w, _xml (strtok (pw->pw_gecos, ",")));
-    xmlTextWriterEndElement (w);
-
     xmlTextWriterStartElement (w, _xml ("meta:creation-date"));
     xmlTextWriterWriteString (w, _xml (buf));
     xmlTextWriterEndElement (w);
 
-    xmlTextWriterStartElement (w, _xml ("dc:creator"));
-    xmlTextWriterWriteString (w, _xml (strtok (pw->pw_gecos, ",")));
-
-    xmlTextWriterEndElement (w);
-
     xmlTextWriterStartElement (w, _xml ("dc:date"));
     xmlTextWriterWriteString (w, _xml (buf));
     xmlTextWriterEndElement (w);
-- 
2.30.2