Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Password Masking

Author
Message
AlexI
19
Years of Service
User Offline
Joined: 31st Dec 2004
Location: UK
Posted: 23rd Oct 2008 11:37
Hi,
I have written the function which you input a string and it returns a masked password back:


However it just crashes the program I cant see why
Any ideas why?
Thanks,
Alex

IanM
Retired Moderator
22
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 23rd Oct 2008 20:58
You haven't allocated any storage for the Output pointer. strcpy doesn't create storage - strdup does that (which is the equivalent of malloc followed by strcpy).

Try this instead:


AlexI
19
Years of Service
User Offline
Joined: 31st Dec 2004
Location: UK
Posted: 24th Oct 2008 01:55

Login to post a reply

Server time is: 2024-11-25 05:20:44
Your offset time is: 2024-11-25 05:20:44