From 378a46975316cb7addf8ea8cd0b74c7144588357 Mon Sep 17 00:00:00 2001 From: Michael Meeks Date: Mon, 16 Aug 1999 21:46:30 +0000 Subject: [PATCH] use new bonobo seek type. --- pdf/xpdf/BonoboFile.cc | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/pdf/xpdf/BonoboFile.cc b/pdf/xpdf/BonoboFile.cc index a97ad08b..ea8f2f71 100644 --- a/pdf/xpdf/BonoboFile.cc +++ b/pdf/xpdf/BonoboFile.cc @@ -57,10 +57,18 @@ int bfseek (BaseFile file, long offset, int whence) { CORBA_Environment ev; + GNOME_Stream_SeekType t; #ifdef HARD_DEBUG printf ("Seek %p %d %d\n", file, offset, whence); #endif - return GNOME_Stream_seek (file, offset, whence, &ev); + if (whence == SEEK_SET) + t = GNOME_Stream_SEEK_SET; + else if (whence == SEEK_CUR) + t = GNOME_Stream_SEEK_CUR; + else + t = GNOME_Stream_SEEK_END; + + return GNOME_Stream_seek (file, offset, t, &ev); } void @@ -70,7 +78,7 @@ brewind (BaseFile file) #ifdef HARD_DEBUG printf ("rewind %p\n", file); #endif - GNOME_Stream_seek (file, 0, SEEK_SET, &ev); + GNOME_Stream_seek (file, 0, GNOME_Stream_SEEK_SET, &ev); } long @@ -81,7 +89,7 @@ bftell (BaseFile file) #ifdef HARD_DEBUG printf ("tell %p\n", file); #endif - pos = GNOME_Stream_seek (file, 0, SEEK_CUR, &ev); + pos = GNOME_Stream_seek (file, 0, GNOME_Stream_SEEK_CUR, &ev); #ifdef HARD_DEBUG printf ("tell returns %d\n", pos); #endif -- 2.43.5