is there any powerful program that can.....

N

news.hku.hk

I'd like to ask if there is any program that can give me the source file
(*.cpp) when i only have the executable file (*.exe) ?

Thanks a lot~
 
J

Joona I Palaste

news.hku.hk said:
I'd like to ask if there is any program that can give me the source file
(*.cpp) when i only have the executable file (*.exe) ?

Such programs are known as decompilers, but they're not perfect. It is
impossible for a decompiler to give you back the same source code as the
original, because compiling is a lossy process. For example, all
comments, formatting and usually all local variable names are lost. This
is known as the "hamburger to cow" problem.
 
B

Ben Pfaff

news.hku.hk said:
I'd like to ask if there is any program that can give me the source file
(*.cpp) when i only have the executable file (*.exe) ?

For me gdb usually does just fine at finding my source files, as
long as I haven't moved or deleted them since I compiled.
 
M

Martijn

Joona said:
Such programs are known as decompilers, but they're not perfect. It is
impossible for a decompiler to give you back the same source code as
the original, because compiling is a lossy process. For example, all
comments, formatting and usually all local variable names are lost.
This is known as the "hamburger to cow" problem.

Not to forget about any optimizations that have been performed :)

And if all symbols have been stripped (such as "local" functions being
static), all gets even worse.

Good luck,

Martijn
http://www.sereneconcepts.nl
 
M

Martin Ambuhl

news.hku.hk said:
I'd like to ask if there is any program that can give me the source file
(*.cpp) when i only have the executable file (*.exe) ?

C++ questions are off-topic here, but I'll answer this anyway: No, there is
not.
If this is your own program, now is the time to learn to back up your
sources. Otherwise, stop trying to steal other people's work.
 
M

Martin Dickopp

Martin Ambuhl said:
news.hku.hk said:
I'd like to ask if there is any program that can give me the source file
(*.cpp) when i only have the executable file (*.exe) ?

[...] Otherwise, stop trying to steal other people's work.

Huh? There are perfectly valid reasons to reverse engineer a program.
If they apply, reverse engineering is also legal in most countries.

Martin
 
L

Lew Pitcher

news.hku.hk said:
I'd like to ask if there is any program that can give me the source file
(*.cpp) when i only have the executable file (*.exe) ?

Certainly, but it's a subroutine of the Graphic Omnicient Device (or G.O.D. for
short), and is only available for the Harlie OS.

--
Lew Pitcher

Master Codewright and JOAT-in-training
Registered Linux User #112576 (http://counter.li.org/)
Slackware - Because I know what I'm doing.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,009
Latest member
GidgetGamb

Latest Threads

Top