« first day (3992 days earlier)      last day (941 days later) » 

3:54 AM
Is the spelling 'awful' being one 'l' away from 'lawful' rather on purpose?
 
 
4 hours later…
7:40 AM
The scientist and the AI-assisted, remote-control killing machine
Killing ... is not so hard, just like it would take a day to destroy a house but 3 months to build one.
Sometimes I would like to take time to congratulate people on taking stupidity to the next level.
 
 
3 hours later…
11:08 AM
@Mikhail i'm working on this Open-Source Project : github.com/ZigRazor/CXXGraph
If someone interested to partecipate or only take a look to my project github.com/ZigRazor/CXXGraph .
 
 
1 hour later…
 
2 hours later…
nwp
2:02 PM
QProcess process;
//... run process
process.write("exit"); //actually makes the process exit
process.closeWriteChannel();
assert(not process.isWritable()); //fails
Thanks Qt.
I get that it's asynchronous, kinda, and maybe the assert comes too quickly, but even after the process is long gone Qt reports it as perfectly writable and not even actually writing to it causes any error.
 
windows or linux?
 
nwp
Windows
 
On windows TerminateProcess is extremely async, it only stops execution semi-immediately. The kernel cleans things up at its leisure
 
nwp
Of course QProcess::ExitStatus only has QProcess::NormalExit and QProcess::CrashExit, QProcess::StillRunning doesn't exist.
 
IIRC querying info on a process after termination is undefined behavior
 
nwp
2:09 PM
QProcess::ProcessState exists. Did they just want to avoid duplicating functionality?
 
other than checking if it's still 'alive' in the sense that the handle exists
 
nwp
I assume if Process Explorer says the process exited then Windows and Qt will do so too.
 
I believe so, AFAIK it checks liveness on the handle
it's kinda a weird race condition, the process can in theory exit between any call
so you have to just ask, see if it fails and then check if it's exited
 
nwp
That would make sense. Throw an exception or return -1 after trying to write to a non-existent process. But no, in Qt land we just pretend the writing succeeded and continue as if nothing happened.
Also I'm disappointed in this Arduino light sensor. It uses an analog pin to give you the brightness, but it's actually just on or off.
 
2:49 PM
anyone have a golden C badge for a dupe nuke?
-2
Q: I was making a simple C program and got an error

Sophia FernandesI get this erorr message - warning: format ‘%d’ expects a matching ‘int’ argument [-Wformat=] I looked it up and tried to fix it, with no avail. Below is my code. Could someone tell me what I'm doing wrong? #include <conio.h> void main() { int num; int amount; printf("\n 0. New Customer"); printf("...

 
nwp
Wow, those answers.
 
Yeah... it needs a dupe nuke ASAP
 
nwp
Someone is trying to close it as a typo which this isn't.
I'll just disengage before I get invested.
 
That was me initially
but I can't change my vote
 
 
2 hours later…
nwp
4:25 PM
Someone put "Disable Windows Updates" on the list of things to do for every new device 🤡
 
 
3 hours later…
7:31 PM
@nwp It's 2013, "sacrifice" 15 mice, process their brains into neurons. It's the 3rd attempt and the cells proliferate. Heat up the incubation equipment. Its Friday night. Set focus points on three hundred individual neurons. Sometimes need to reset all the points because the objective hits the sample. 3:00 am all systems are go. Start imaging. It's winter. Cross empty streets and sleep. Come back on Saturday. Computer says "Windows has successfully installed updates", no data was acquired.
 
8:12 PM
@JerryCoffin Did you ever compare the walltimes/performance for taoJSON vs RapidJSON?
I gotta lot of json-ing to do and not sure which library
 
 
3 hours later…
10:49 PM
So, anybody compare avro to protobuf?
 
11:03 PM
@Mikhail Seems like I did a little bit of comparing once, but not enough to reach a meaningful conclusion beyond "both plenty fast" (for what I cared about at the time).
 
Planning on writing a 20 gigabyte json file
wish me luck
 
@Mikhail At that point, most JSON stuff is likely to fall to pieces. Their file reading/writing will usually be only via iostreams, which itself is usually pretty weak for files that size.
 
So you're saying I should write another JSON library?
with fmt, blackjack, and hookers
C/C++ feels like undefined behavior, for example, if C=0 or C=1, also something about ghosts of junction points.
 
@Mikhail Probably not. But it might easily make sense to write your own streambuffer, to act as the back-end for the iostream you use to write this. If I'm not mistaken, even Microsoft's use POSIX-style open/creat/read/write. For something like this, you probably want to use CreateFile and WriteFile directly, with a large enough buffer that you can use FILE_FLAG_NO_BUFFERING.
I haven't re-checked recently with something like a really high-end SSD, but with older drives, this used to give pretty much the rated speed of the hardware (which is to say: at least double that of normal iostreams).
As I recall, you did some playing with this sort of stuff with RAID a year or two ago, didn't you?
 
11:22 PM
 

« first day (3992 days earlier)      last day (941 days later) »