Index: libs/libmythtv/datadirect.cpp
===================================================================
--- libs/libmythtv/datadirect.cpp	(revision 17239)
+++ libs/libmythtv/datadirect.cpp	(working copy)
@@ -1618,7 +1618,7 @@
 
     VERBOSE(VB_GENERAL, "SaveLineupToCache("<<lineupid<<") -- success");
 
-    chmod(fn.ascii(), 0666); // Let anybody update it
+    makeFileAccessible(fn); // Let anybody update it
 
     return true;
 }
Index: libs/libmythtv/previewgenerator.cpp
===================================================================
--- libs/libmythtv/previewgenerator.cpp	(revision 17239)
+++ libs/libmythtv/previewgenerator.cpp	(working copy)
@@ -460,7 +460,7 @@
 
     if (small_img.save(filename, "PNG"))
     {
-        chmod(filename.ascii(), 0666); // Let anybody update it
+        makeFileAccessible(filename); // Let anybody update it
 
         VERBOSE(VB_PLAYBACK, LOC +
                 QString("Saved preview '%0' %1x%2")
@@ -474,7 +474,7 @@
     if (QFileInfo(filename.ascii()).exists() &&
         small_img.save(newfile.ascii(), "PNG"))
     {
-        chmod(newfile.ascii(), 0666);
+        makeFileAccessible(newfile);
         rename(newfile.ascii(), filename.ascii());
 
         VERBOSE(VB_PLAYBACK, LOC +
Index: programs/mythbackend/mythxml.cpp
===================================================================
--- programs/mythbackend/mythxml.cpp	(revision 17239)
+++ programs/mythbackend/mythxml.cpp	(working copy)
@@ -1237,6 +1237,8 @@
 
     img.save( pRequest->m_sFileName.ascii(), "PNG" );
 
+    makeFileAccessible(pRequest->m_sFileName);
+
     delete pImage;
 }
 
Index: libs/libmyth/util.cpp
===================================================================
--- libs/libmyth/util.cpp	(revision 17239)
+++ libs/libmyth/util.cpp	(working copy)
@@ -928,6 +928,29 @@
     return tmpFileName;
 }
 
+/** \fn makeFileAccessible(QString)
+ *  \brief Makes a file accessible to all frontends/backends.
+ *
+ *   This function abstracts the functionality of making a file accessible to
+ *   all frontends and backends.  Currently it contains a permissions hack that
+ *   makes a file accessible even on a system with an improperly configured
+ *   environment (umask/group) where the frontend and backend are being run as
+ *   different users or where a NFS share is used but UID's/GID's differ on
+ *   different hosts.
+ *
+ *   Though the function currently only changes the file mode to 0666, by
+ *   abstracting the functionality, it will be easier to make changes in the
+ *   future if a better approach is chosen.  Similarly, using this function
+ *   allows the hack to be applied only when required if code is written to
+ *   detect or allow the user to specify their system is misconfigured.
+ *
+ *  \param filename   Path of file to make accessible
+ */
+void makeFileAccessible(QString filename)
+{
+    chmod(filename.ascii(), 0666);
+}
+
 double MythGetPixelAspectRatio(void)
 {
     float pixelAspect = 1.0;
Index: libs/libmyth/util.h
===================================================================
--- libs/libmyth/util.h	(revision 17239)
+++ libs/libmyth/util.h	(working copy)
@@ -83,6 +83,7 @@
 MPUBLIC long long copy(QFile &dst, QFile &src, uint block_size = 0);
 MPUBLIC QString createTempFile(QString name_template = "/tmp/mythtv_XXXXXX",
                                bool dir = false);
+MPUBLIC void makeFileAccessible(QString filename);
 MPUBLIC unsigned long long myth_get_approximate_large_file_size(
     const QString &fname);
 
