Memory Safe C++

preview_player
Показать описание


🔥🔥🔥 SOCIALS 🔥🔥🔥
Рекомендации по теме
Комментарии
Автор

Okay this is the sort of click bait I can get behind

valmirius
Автор

I thought it's a YouTube glitch 😂😂

Movie-MOVlE
Автор

I shared it with my gf because of the first part, you're reaching a new target audience with this 😂

samelosito
Автор

STOP!! YOU HAVE VIOLATED MEMORY! Pay the court a fine or serve your sentence

nicholasfinch
Автор

If you date him, you'll know that once you die, your memory will be save.

JonnesTT
Автор

As a JavaScript developer this is very helpful

AzurePages
Автор

Not only is he not cheating, he's making way more money than the guy that's cheating

procyon.lotor
Автор

I love the beginnings to these videos now, i never used to interact but i did watch them, hilarious..love it.

kaatlev
Автор

As someone who has used GDB and knows exactly what he was talking about and doing...
I feel very called out by this.

DaGlitchMaster
Автор

HALT! YOU HAVE COMMITTED CRIMES AGAINST MALLOC AND HER PROCESSES. WHAT SAY YOU?

OmegaF
Автор

To answer the question again, I’m just chilling in my garage listening to music thinking I could probably afford a new tool box in a month or two. Also I gotta wash the dogs (she asked if I could wash the dogs). I really don’t like washing the dogs…. So I’m gunna measure this one spot where I think this new tool box could go again (I know it will fit there’s nothing there) then I’ll wash the dogs.

iandillard
Автор

Good men are always out there, women just always think the beast (assholes) will turn into the prince that will save the princess.
Sadly our society thinks it’s cool to be a douche, but nobody learns to be decent.

NoHandle
Автор

As a long time C++ dev, the problem is… you do not know how to write memory safe C++

ProdBySneezy
Автор

I don't cheat because I don't have anyone to cheat on, or with

ninjasack
Автор

So, from the code I can see in this short, this is the function:
void handleClient(int cfd) {
std::cout << "handling client ;)" << std::endl;

std::array<char, 512> msgbuffer;

uint32_t bytesread = read(cfd, msgbuffer.data(), msgbuffer.size());

std::string request(std::begin(msgbuffer), std::end(msgbuffer));

std::cout << request << std::endl;
}
Here's the translation of it to Rust (but with Rust's sockets instead of raw file descriptors):
fn handClient(cfd : &mut std::net::TcpStream) { //at least I except with to be TCP
println!("handling client ;)");

let mut msgbuffer : [u8; 512] = [0; 512];

let bytesread : usize = cfd.read(&mut msgbuffer).unwrap();

let request : String = unsafe { }; //this is for this problem actually not important
//also, one could argue that we just do ASCII here, but by default Rust forces you to use UTF8 or use completely other types
//so, the safe version (the from_utf8 function) would also check if it's actually valid UTF8

println!("{}", request);
}

If that's not it, could you please at least link to the code somewhere (or better, show the whole thing outright)?
Because otherwise this short is kinda useless.

kuhluhOG
Автор

I swear this guy has the best bait intros HAHAHA

yukisnoww
Автор

I love how you make a joke out of this. Laughing and learning

sandtrick
Автор

“wyd” homie im having a fruitful marriage

kademeyer
Автор

Keep these coming these have been cracking me up 😂

StevenCroghan
Автор

Thanks I’ll remember that! C has been like decrypting an ancient wizard tome for me; and just as fun!

sethgaston