]> www.fi.muni.cz Git - evince.git/blobdiff - backend/dvi/mdvi-lib/tfmfile.c
[l10n] Updated German doc translation
[evince.git] / backend / dvi / mdvi-lib / tfmfile.c
index b8235bfb8f26b5bceacf473b2778f10e2ba63e10..8c2a30b26009aacc82601fa6e679572240e02085 100644 (file)
@@ -14,7 +14,7 @@
  *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  */
 
 #include <config.h>
@@ -172,7 +172,8 @@ int tfm_load_file(const char *filename, TFMInfo *info)
        /* We read the entire TFM file into core */
        if(fstat(fileno(in), &st) < 0)
                return -1;
-       if(st.st_size == 0)
+       /* according to the spec, TFM files are smaller than 16K */
+       if(st.st_size == 0 || st.st_size >= 16384)
                goto bad_tfm;
 
        /* allocate a word-aligned buffer to hold the file */