/dpt/ - Daily Programming Thread

prev
What are you working on, Any Forums?

Attached: 1651681593949.jpg (1280x720, 249.64K)

Other urls found in this thread:

8112310.fs1.hubspotusercontent-na1.net/hubfs/8112310/OpenSSF/White House OSS Mobilization Plan.pdf
twitter.com/AnonBabble

Writing my own little C++ utility library.

but did you implement your own data structures and re-implement the STL first?

No, the data structures in the standard library are more than sufficient.

I'm telling the committee about this, they will not be pleased.

I want Herb to touch my no-no-place.

present it as a discussion topic, and maybe in 12 years they'll deliberate on whether they can discuss it

in the console?

nakadashi rize copy girl

>Because lower-level software has more operational constraints than higher-level software (e.g. it typically cannot tolerate a runtime or memory management via garbage collection), developing a memory safe language suitable for systems software is particularly challenging. The Rust language has met that challenge, however, and is an excellent candidate for replacing C in many systems applications.
>We plan to invest in the tools that allow systems engineers to move their software to Rust. This means investing in improving package management, compilers, and Foreign Function Interface (FFI) generators. In many cases this will include providing interfaces compatible with existing widely-used components to enable transition. With these tools, adoption of a memory safe alternative will scale much faster without replication of efforts.
based
8112310.fs1.hubspotusercontent-na1.net/hubfs/8112310/OpenSSF/White House OSS Mobilization Plan.pdf

>official glowie language

man i love git-gui and gitk
why do people use shit like sourcetree

I have some friends that are also developers. I dont think they do for the hobby, tho.
How can i talk with them to make something together for fun?

Attached: seu madroga.png (427x450, 78.54K)

well lucky for you, I know your friends personally and can say, with authority, that all you need to do is propose a fangame for Gawr Gura. They will instantly be on board.

Attached: gurasea.jpg (512x512, 56.68K)

¡Ron Damón!

DUDE SWITCH STATEMENTS ALWAYS GET OPTIMIZED TO JUMP TABLES
except when they aren't

job security

I'm using getopt on my program and I seem to be having a bit of a problem with the logic of my switch statement:

int port_flag = 0;
// while ((opt = getopt_long(argc, argv, short_options, long_options, NULL)) != -1)
while ((opt = getopt(argc, argv, short_options)) != -1)
{
switch(opt)
{
case 'f':
if (port_flag == 1)
{
filename = malloc(strlen(optarg) + 1);
strcpy(filename, optarg);
sendto(sockfd, filename, strlen(filename), 0, (struct sockaddr *)&serverAddr, sizeof(serverAddr)); //enviamos el mensaje (UTILIZANDO optarg)
break;
}
case 'h':
usage(stdout, program_name);
exit(EXIT_SUCCESS);
case 'p':
port = atoi(optarg); // Asignamos el puerto
serverAddr.sin_port = htons(port);
port_flag = 1;
continue;
case ':':
printf("La opcion necesita un valor\n");
usage(stdout, program_name);
exit(EXIT_FAILURE);
case '?':
printf("Opcion desconocida: %c\n", optopt);
usage(stdout, program_name);
exit(EXIT_FAILURE);
}
}

It probably is something very stupid but I can't point it out. Maybe I need to sleep.
Can anyone give me a hand? Thanks a lot.

1. what's the actual problem?
2. you're only conditionally breaking out of case 'f'. you probably don't want to go on to case 'h' if port_flag isn't 1

Problem is, if I run it as:
./client -p 2020 -f nigger.txt
it works fine, but if I do
./client -f nigger.txt -p 2020
it just stays still (case 'f') doesn't get executed

Trying to learn some git.
Do you guys delete feature branches after they are merged to master? Or do you delete the local branches but keep the remote branches?

Meant to write:
It just stays still (case 'f' doesn't get executed)

>Do you guys delete feature branches after they are merged to master? Or do you delete the local branches but keep the remote branches?
I usually delete local branches and keep the remotes for posterity.