After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 439841 - 2.2.8: file stream's seek and reset broken
2.2.8: file stream's seek and reset broken
Status: RESOLVED FIXED
Product: gmime
Classification: Other
Component: general
2.2.x
Other All
: Normal major
: ---
Assigned To: Jeffrey Stedfast
Jeffrey Stedfast
: 426377 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2007-05-20 04:44 UTC by Charles Kerr
Modified: 2007-05-21 13:26 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
fixes problems in file stream -- doesn't touch cat stream (612 bytes, patch)
2007-05-20 04:46 UTC, Charles Kerr
none Details | Review

Description Charles Kerr 2007-05-20 04:44:42 UTC
GMimeFileStream's seek uses SEEK_END for a value calculated for SEEK_SET.
This is causing problems right now in Pan.

GMimeFileStream's reset calls fseek to reset, but doesn't update
the stream's position variable.

As an aside, GMimeStreamCat likewise doesn't update its position
variable in its reset function, but I'm not positive that it's a
bug there and just wanted to bring it to your attention.
Comment 1 Charles Kerr 2007-05-20 04:46:06 UTC
Created attachment 88469 [details] [review]
fixes problems in file stream -- doesn't touch cat stream
Comment 2 Charles Kerr 2007-05-20 04:48:56 UTC
*** Bug 426377 has been marked as a duplicate of this bug. ***
Comment 3 Jeffrey Stedfast 2007-05-21 13:26:58 UTC
I recently changed reset semantics such that returning 0 from the implementation will set the stream->position = stream->bound_start in gmime-stream.c

however, good catch on the SEEK_END bit, that is definitely broken :)