radareorg / radare2

UNIX-like reverse engineering framework and command-line toolset
https://www.radare.org/
GNU Lesser General Public License v3.0
20.69k stars 3.01k forks source link

Sometimes a comment is not just a comment #4889

Closed jduck closed 8 years ago

jduck commented 8 years ago

For example, see:

[0x08048400]> #dr PC
Error: provided size must be size > 0

:-/

radare commented 8 years ago

Comments start by '# ' see #? For help on why is this err

On 15 May 2016, at 08:13, Joshua J. Drake notifications@github.com wrote:

For example, see:

[0x08048400]> #dr PC Error: provided size must be size > 0 :-/

— You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub

jduck commented 8 years ago

Okay! Thanks. Although this is surprising, I can swallow that it is working as intended. Maybe sprinkling some more help for the user would be good though. Something like "Error: provided size must be > 0 (see #?)"

radare commented 8 years ago

Im aware this is confusing so maybe we should be more strict on this and only catch the valid values. But the hashbang should be kept.. and for hashing most ppl is used to it.. So if you think inna better command for the hashing we can jump of here and just keep #! As an exception

On 15 May 2016, at 10:21, Joshua J. Drake notifications@github.com wrote:

Closed #4889.

— You are receiving this because you commented. Reply to this email directly or view it on GitHub

jduck commented 8 years ago

Maybe 'ch' for calculate hash?

jduck commented 8 years ago

Also, there's nothing using "h" it seems...

radare commented 8 years ago

Or ph

Print Hash

On 15 May 2016, at 22:05, Joshua J. Drake notifications@github.com wrote:

Maybe 'ch' for calculate hash?

— You are receiving this because you commented. Reply to this email directly or view it on GitHub

jduck commented 8 years ago

In shell scripts, the shebang is a special case where the first line is the only line it works on.

radare2/dev$ cat > test.sh ; chmod 700 test.sh
# monkey
#!/bin/sh -c id
echo haha
radare2/dev$ ./test.sh 
haha
radare commented 8 years ago

yep i know, but here in r2 is used to launch rlang plugins which are used by r2pipe

On 15 May 2016, at 22:07, Joshua J. Drake notifications@github.com wrote:

In shell scripts, the shebang is a special case where the first line is the only line it works on.

— You are receiving this because you commented. Reply to this email directly or view it on GitHub https://github.com/radare/radare2/issues/4889#issuecomment-219307545

jduck commented 8 years ago

And that is necessary at any time during the input stream? I'm not familiar with rlang plugins or r2pipe. I guess I have some reading to do. Any pointers?