flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
vid
sorry, i don't understand you, please try to rewrite it (with shorter sentences
![]() |
|||
![]() |
|
f0dder
There's no OS-independant way to do this. Writing to memory doesn't automatically write to disk. And under some operating systems you cannot even write to your exeuctable file while the program is running (windows*, to name one).
If you only want read-access to the data when the program is running, you can use another program to write the data there. But you still need OS-dependant way of reading the data. Pretty moot argument anyway, since executable files are os-dependant. *) yes, it's possible to write to running-exe, but it's hacky. Even the cleanest way to do it (copy exe to temp, launch with special args, etc.)is cumbersome. |
|||
![]() |
|
DrenThales
I'm pretty sure I could write data during preprocessor and assembly time (but that would only let me document preprocessor and assembly passes, likewise), but, that too is OS dependant, because the compile is run via that particular OS version of FASM.
It would seem I was being somewhat naive when I originally posted the thread. In any case though, I'll just use my current OS for output, for the time being. And because my current OS happens to be Linux, I can just use a redirect ( > ) or pipe ( | ) to store and/or process it ( ![]() Thanks for helping to alieve my temporary lapse into naivety, as it were. |
|||
![]() |
|
LocoDelAssembly
Quote:
Remember you can do that on Windows too ![]() |
|||
![]() |
|
DrenThales
You can?, I wasn't aware. Course, I never really used DOS-type commands and such much, besides for running a few compilers for certain programming languages. Which would probably explain me not having encountered it (seeing as most MS Windows apps have GUIs, recently).
|
|||
![]() |
|
LocoDelAssembly
try "echo gmail.com | nslookup" and "echo gmail.com | nslookup > out.txt" or just "nslookup gmail.com > out.txt" (the last two produces different output each other)
[edit] Another example can be creating a file named hosts.txt like this: Code: gmail.com hotmail.com microsoft.com And then using it like "type hosts.txt | nslookup" or "nslookup < hosts.txt" (since Windows supports stdin redirection too). Sumarizing, in Windows you can redirect stdin, stdout and stderr and you can use pipes as well[/edit] |
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.
Website powered by rwasa.