+ 1

(C++)Help! Why this code is running with error?

code: https://code.sololearn.com/c744Ygo4hZwh/?ref=app https://code.sololearn.com/cCr1NdMwwXeF/?ref=app https://code.sololearn.com/cp1ZrfRZbRmz/?ref=app error: Segmentation fault why this error occurred? how to fix it? edit: the error is in processor.h. i dont know why, when "if (brand == "AMD")" executed, the error occurred

26th Dec 2017, 2:58 AM
Kevin AS
Kevin AS - avatar
33 Answers
+ 3
@saurabh its a program to debug your c/c++ program in linux/gnu.
26th Dec 2017, 5:18 AM
Kevin AS
Kevin AS - avatar
+ 3
I don't know much about it but it says compiler version g++ 6.3.0
26th Dec 2017, 5:26 AM
Saurabh Tiwari
Saurabh Tiwari - avatar
+ 3
thnx @Jamie,@Kevin and @ace😄
26th Dec 2017, 5:28 AM
Saurabh Tiwari
Saurabh Tiwari - avatar
26th Dec 2017, 3:07 AM
Kevin AS
Kevin AS - avatar
+ 2
@jamie yap yap yap
26th Dec 2017, 4:52 AM
Kevin AS
Kevin AS - avatar
+ 2
good refrence
26th Dec 2017, 4:55 AM
Kevin AS
Kevin AS - avatar
+ 2
what is a gdb
26th Dec 2017, 5:14 AM
Saurabh Tiwari
Saurabh Tiwari - avatar
+ 2
whoa!! sounds gud cant it be used in windows or android??
26th Dec 2017, 5:19 AM
Saurabh Tiwari
Saurabh Tiwari - avatar
+ 2
one more question?? as I m a beginner should I learn it?
26th Dec 2017, 5:24 AM
Saurabh Tiwari
Saurabh Tiwari - avatar
+ 2
you must learn it. its important
26th Dec 2017, 5:27 AM
Kevin AS
Kevin AS - avatar
+ 1
in computer. with gcc
26th Dec 2017, 3:06 AM
Kevin AS
Kevin AS - avatar
+ 1
@Ace yeah im trying with gdb here. but im little confuse. (still noob with gdb)
26th Dec 2017, 3:56 AM
Kevin AS
Kevin AS - avatar
+ 1
i cant believe it. you right jamie. are you using gdb?
26th Dec 2017, 4:12 AM
Kevin AS
Kevin AS - avatar
+ 1
@ace good advice.
26th Dec 2017, 4:26 AM
Kevin AS
Kevin AS - avatar
+ 1
@ace and @jamie thanks for help and advice. i almost delete this project because frustrated
26th Dec 2017, 4:31 AM
Kevin AS
Kevin AS - avatar
+ 1
gdb is something new for me. i will learn more debugging with gdb
26th Dec 2017, 4:48 AM
Kevin AS
Kevin AS - avatar
0
:v
26th Dec 2017, 3:10 AM
Kevin AS
Kevin AS - avatar