Bug 6108 - error in strstream library
error in strstream library
Status: CLOSED WORKSFORME
Product: Red Hat Linux
Classification: Retired
Component: gcc (Show other bugs)
6.0
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: David Lawrence
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 1999-10-19 19:53 EDT by vonmatt
Modified: 2008-05-01 11:37 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 1999-10-19 22:50:40 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description vonmatt 1999-10-19 19:53:04 EDT
The following program leads to a segmentation fault in
RedHat 6.0.  This used to work in release 5.2.

#include <iostream.h>
#include <strstream.h>
#include <stdio.h>

const char* input =
  "1: The quick brown foxes jumped over the lazy dog.\n"
  "2: The quick brown foxes jumped over the lazy dog.\n"
  "3: The quick brown foxes jumped over the lazy dog.\n"
  "4: The quick brown foxes jumped over the lazy dog.\n"
  "5: The quick brown foxes jumped over the lazy dog.\n"
  "6: The quick brown foxes jumped over the lazy dog.\n"
  "7: The quick brown foxes jumped over the lazy dog.\n"
  "8: The quick brown foxes jumped over the lazy dog.\n";

int main ()

{ istrstream istr (input);
  int c;
  while ((c = istr.get ()) != EOF) {
    cout << (char) c;
  }
  return 0;
}


Urs von Matt
Ise Inc.
vonmatt@ise.com
Comment 1 Bill Nottingham 1999-10-19 22:50:59 EDT
Works fine for me in both 6.0 and 6.1. Make sure you aren't trying to link against
an incompatible libg++.

Note You need to log in before you can comment on or make changes to this bug.