tr2.getChar()
<< " " << strlen(str2.getChar()) << endl;
return EXIT_SUCCESS;
}
btw, Im doing this as excersise, so any buggy things on the code please let me
know.
--
Summary: strcpy bug? or mine?
Product: gcc
Version: 3.4.3
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: rolosworld at gmail dot com
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19172
--- Additional Comments From rolosworld at gmail dot com 2004-12-28 01:00
---
(In reply to comment #1)
> You forgot C strings are null terminated.
I did this:
word = new char( strlen(str) + 1 );
word[strlen(str)] = '\0';
and still get the same output..?
--
--- Additional Comments From rolosworld at gmail dot com 2004-12-28 01:23
---
Im using:
"khgukytit8igddd0"
"0123456789qwertypoopp"
Im compiling the code with:
g++
--- Additional Comments From rolosworld at gmail dot com 2004-12-28 01:30
---
ok, I'll keep experimenting here, I belive its probably one bug from me :-/
I'll try the C equivalent and try to learn from this! lol
thanks for the help
--
http://gcc.gnu.org/bugzilla/show_
--- Additional Comments From rolosworld at gmail dot com 2004-12-28 01:36
---
true, didn't notice the brackets.
scary bug from me lol
thank guys
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19172