Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
zergstain
Dec 15, 2005

robostac posted:

You'll probably find quite a few sites will ask for the verification as its now enabled on your account.

This site made me choose a password. It didn't open in a new tab that I could just close either. I assumed anyone else who participated in the program would also make me choose a password the first time. But I pretty much never shop at a place that isn't Amazon, eBay or Apple.

I love living in Canada. $10 for the cheapest shipping available and it will take at least 2 weeks.

Adbot
ADBOT LOVES YOU

JetsGuy
Sep 17, 2003

science + hockey
=
LASER SKATES
I started using 1password about two years ago, and have never looked back. Now all my passwords are at least 15 character strings of random letters, symbols, and numbers. Unless I get some dumb site that requires "no special characters".

Of course, the danger is that the "master password" can be stolen I guess.


EDIT
Honestly though, the SONY gently caress up of storing our info in just a step above plain text really made me realize how dumb it was to have only two passwords: "one for important things" and one for "dumb poo poo". The SONY was on the important list since they had my CC...

sigh...

zergstain posted:

I love living in Canada. $10 for the cheapest shipping available and it will take at least 2 weeks.

I order poo poo off amazon prime, get the free "2 day" shipping, and it usually arrives at my door the next day at COB. :smug:

Zaphod42
Sep 13, 2012

If there's anything more important than my ego around, I want it caught and shot now.

Thermopyle posted:

Signed up for a new bank today.

The online signup gave me a password for their online banking. When I logged in it prompted me to change my password along with this message:

quote:

awesome online banking posted:
Passwords are case sensitive, must be between 6 and 8 characters in length

Hey, that may be short, but I was just reading about somebody (possibly a bank, something major) that didn't have a password limit but would simply silently truncate any characters past 9 or something. :suicide:

JetsGuy
Sep 17, 2003

science + hockey
=
LASER SKATES

Zaphod42 posted:


Hey, that may be short, but I was just reading about somebody (possibly a bank, something major) that didn't have a password limit but would simply silently truncate any characters past 9 or something. :suicide:

I had a bank that used to do that. Here's the kicker:

When you put in a new password, it truncated it to 9 characters.

HOWEVER, when you entered it into the the login, they had this weird thing where whatever the last character you entered past the 9th would overwrite the 9th.

So you could very easily:

1) Make a password of 10 characters, say "password12"
2) Not know you were truncated to 9, and then when you logged in, the system would say you were wrong because the password you'd enter would be "password2" instead of the "password1" the system logged.

I only figured it out when I started noticing the way the dots were deleting the last one and putting in a new one after character 9.

pokeyman
Nov 26, 2006

That elephant ate my entire platoon.

Munkeymon posted:

6 min 8 max, IIRC, and if the way they integrate with Newegg is their normal, you can just ignore the verification by closing the tab and everything will still work fine, so I assume they only check that if they already suspect something funny is going on with your account or you buy something expensive.

Isn't Verified by Visa the one where you can trivially set a new password anytime you're asked for the current one? I remember doing that each time it came up.

Anecdotally (friend who talked to someone from Visa) everyone knows Verified by Visa contributes nothing to the security of the transaction, but inertia/politics prevents its removal (or modification into something useful). It is as pointless as it seems.

Plorkyeran
Mar 22, 2007

To Escape The Shackles Of The Old Forums, We Must Reject The Tribal Negativity He Endorsed

pokeyman posted:

Isn't Verified by Visa the one where you can trivially set a new password anytime you're asked for the current one? I remember doing that each time it came up.

Anecdotally (friend who talked to someone from Visa) everyone knows Verified by Visa contributes nothing to the security of the transaction, but inertia/politics prevents its removal (or modification into something useful). It is as pointless as it seems.
Well, it never was intended to protect the cardholder in any way. In theory it stops certain kinds of credit card fraud: if you make an order and use the Verified by Visa password you set with a previous order, then claim that your card was stolen between the two orders, something is obviously up. I have no idea if this actually turned out to be useful in practice.

substitute
Aug 30, 2003

you for my mum

JetsGuy posted:

... SONY gently caress up

Sony is awesome. I had set the PS3 to ask for the password before PSN purchases, so for the past few weeks the store was asking for my password even when I hit the download buttons on free demos. I input random characters every single time and the download would start. I never tested an actual credit card purchase.

Why even prompt for it on free stuff, and then not even verify? Stupid program flow.

Munkeymon
Aug 14, 2003

Motherfucker's got an
armor-piercing crowbar! Rigoddamndicu𝜆ous.



pokeyman posted:

Isn't Verified by Visa the one where you can trivially set a new password anytime you're asked for the current one? I remember doing that each time it came up.

Anecdotally (friend who talked to someone from Visa) everyone knows Verified by Visa contributes nothing to the security of the transaction, but inertia/politics prevents its removal (or modification into something useful). It is as pointless as it seems.

I haven't changed it since I set it up in ~2007 or so so I don't know how easy it is. Good to know it actually is about as useless as I thought, though.

pokeyman
Nov 26, 2006

That elephant ate my entire platoon.

Plorkyeran posted:

Well, it never was intended to protect the cardholder in any way. In theory it stops certain kinds of credit card fraud: if you make an order and use the Verified by Visa password you set with a previous order, then claim that your card was stolen between the two orders, something is obviously up. I have no idea if this actually turned out to be useful in practice.

I think it was positioned as a benefit for cardholders as well as merchants, and merchants might have to implement it in order for Visa to screw them over less often. The anecdote was basically that it's a placebo, with no practical effect on either side.

But that's about the extent of my knowledge of all of this, so I'm the horror.

shrughes
Oct 11, 2008

(call/cc call/cc)
I am the horror :(

code:
struct protob_pointee_t {
    uintptr_t tag : 1;
    uintptr_t refcount : sizeof(uintptr_t) - 1;

    protob_pointee_t(uintptr_t _tag) : tag(_tag), refcount(0) { }
};

da keebsta knicca
Sep 12, 2000

Oh Ruutu, you are such a card.
I don't know were to put this but I just need vent on this. I been out of the .NET game for like 4 years but I am pretty sure pushing changes and setting up dev environments isn't this bad.

This isn't code it is a quote from a $100/hour ASP.NET developer that my new client paid... They have a custom CMS they got conned into. They were uploading their own videos through it but the hosting couldn't handle it so I got them on Vimeo Pro ($200 for 250k plays). We needed a custom field for embed codes... because every little piece of the goddamn website is custom field in the CMS... then on the front end IF embed_code display embed_code if not display uploaded video... like 2 hours of work tops with launching... He came back with a 20hour quote at $100/hour and I was like "justify it". Here is the hour break down. WTF. Oh he had their setup with no development server either to see changes.. he has been working on it for 3 years to the tune of $40k + so he charged for that to be setup. The whole thing makes me sick.

quote:

Add Option for Video System
In order to add an option to use Vimeo Pro embed OR the option that is there now it will require the following – 20 hours total:
- setup a staging environment to run side by side with the production environment, this includes, new SVN branch with
code checkin, new database cloned with new Maintenance Plans + Backup Jobs and adding to our Offsite Backup System,
setup new Hudson job for publishing – 3 hours
- modify the database and DAL (Data Access Layer), Models and Controllers – 2 hours
- modify the CMS to allow both video upload(temporarily) and embed code on Add and Edit Video – 2 hours
- modify the CMS to allow both video upload(temporarily) and embed code on Add and Edit Discipline – 1 hour
- modify the frontend on the staging server to show the embed code on the Video Preview Page – 1.5 hours
- modify the frontend on the staging server to show the embed code on the Video Play page – 1.5 hours
- modify the frontend on the staging server to show the embed code on the Discipline Page – 1 hour
- modify the frontend to show the embed code if it exists, if not, fall back on the manually uploaded version – 1 hour
- Upon successful testing and confirmation the Vimeo integration works the way you want it to we will then
- migrate the staging frontend to the production server – 1 hour
- migrate the staging backend to the production server – 1 hour
- add Vimeo integration to Mobile Site – added – 2 hours
- Test Driven Development (User Test Cases) – 4 hours <-- 4 hours of testing for 2 form fields... the client tried to publish an unclosed tag in the custom field, and it crashed the whole page... after launch.

Guy was also days late on implementing this. He also never implemented any of the changes on the staging server, just straight the development. I am new to the freelance world, I need to learn how to game like this guy, and up my rate gently caress.

da keebsta knicca fucked around with this message at 22:59 on May 3, 2013

zeekner
Jul 14, 2007


Ellipses don't do what you think they do. You'll never use them for their intended purpose, so please don't use them.

a nest of hornets
Nov 17, 2012

by Ralp
Allow me to take you on a photo tour of the most hosed up project I've ever ran away from. This was supposed to be a 3 month long project, for some reason they kept this bozo around for SIX MONTHS past the date he was supposed to ship on. (I was in and out in 4 weeks)

This was the most recent commit. I can't tell if he's learned something over the 9 months he's been doing this, or he's just run out of steam.



:wtf:
:lol: 20k lines added, 15k removed
30k lines added :supaburn:


Last but not least, the crown jewel of this clusterfuck, the initial commit:
:aaaaa:

This dude's submodule game is clearly off the chain. Retina assets used as many as 3 unique prefixes (-retina, -hd, and @2x), and they were all shoved in asset folders across the entire codebase.

This was a fairly simple "happy meal toy" iPad game/app meant to promote a children's product line, that he had somehow turned into the most tangled mess I've ever seen. It was a very very basic cocos2d game, it should have been extremely straightforward to create. Instead, he seemed to find internet examples and stretched them to incredible lengths.

Here are some samples of his nearly 300 line runloop from just one of the games:


My favorite part is where he loops over every piece of the level in this array, 60 times a second.


The PM 'just wanted me to polish a few things up', but the nature of the codebase meant that any fix, big or small, came with several regressions. I told him that was a pretty good indicator that we were "hosed". He asked me how long it would take to rewrite (no thanks!), and wanted to know what he should tell the client when they find all the bugs/crashes. I told him "the truth? that you hired an incredibly inept developer and kept him around for 9 months??"

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe

FOLLOW ME BRUH posted:

My favorite part is where he loops over every piece of the level in this array, 60 times a second.


The rest of that looks pretty horrible, but what's horrible about this? How many parts do you have in a level? It's only once you get to around 50,000 elements that it might start to make a difference, in the general case. Computers are loving fast.

What's the faster way to do it?

Rocko Bonaparte
Mar 12, 2002

Every day is Friday!

Salvador Dalvik posted:

Ellipses don't do what you think they do. You'll never use them for their intended purpose, so please don't use them.
My problem is I read them... as if... they've been stabbed... 50 times... and it's hard... to speak...

Lord Booga
Sep 23, 2007
Huh?
Grimey Drawer

Suspicious Dish posted:

The rest of that looks pretty horrible, but what's horrible about this? How many parts do you have in a level? It's only once you get to around 50,000 elements that it might start to make a difference, in the general case. Computers are loving fast.

What's the faster way to do it?

He did say it was supposed to be an iPad app, which I guess are a lot less powerful than your average desktop or laptop. I suppose without knowing how expensive some of those functions are, or how many iterations there are, you can't really tell.

a nest of hornets
Nov 17, 2012

by Ralp

Suspicious Dish posted:

The rest of that looks pretty horrible, but what's horrible about this? How many parts do you have in a level? It's only once you get to around 50,000 elements that it might start to make a difference, in the general case. Computers are loving fast.

What's the faster way to do it?

Cocos2d has a whole bunch of built in tilemapping support. He opted to use none of it, and instead implemented this leaky as gently caress "thing". He didn't even use the image cache right.

I don't even know what I would do to make this better. Delete it? :v:

In all seriousness, a slightly better approach might be something like having the tiles notify the scene when they've gone offscreen, so that you can remove them and add the next one. You wouldn't have to do silly things like use an int to keep track if you're traveling left or right, or rely on magic numbers, or check every tile every frame.

Oh! I forgot to mention: the way he wrote most of the game, when it came time to add retina assets, everything broke. So he went through the whole codebase and added these retina/HD bools, and in various places, if those were yes, magic numbers got multiplied by 2.

Lord Booga posted:

He did say it was supposed to be an iPad app, which I guess are a lot less powerful than your average desktop or laptop. I suppose without knowing how expensive some of those functions are, or how many iterations there are, you can't really tell.

This is a great point. I'd like to point out that, this code would have never, ever, EVER worked on a 1st gen iPad. It slows down my iPad mini if I leave it open for 10 minutes. The iPad 4 could probably run 30 instances of this lovely game without issue. It's kind of a beast.

Also something something spoiled idiots arc memory management :argh:

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe

FOLLOW ME BRUH posted:

In all seriousness, a slightly better approach might be something like having the tiles notify the scene when they've gone offscreen, so that you can remove them and add the next one. You wouldn't have to do silly things like use an int to keep track if you're traveling left or right, or rely on magic numbers, or check every tile every frame.

How would the tiles notify the scene when they've gone off-screen without checking them every frame?

a nest of hornets
Nov 17, 2012

by Ralp

Suspicious Dish posted:

How would the tiles notify the scene when they've gone off-screen without checking them every frame?

Any number of ways. The most rigid, least complicated method, in this situation (because the character always moves at a static speed), is to schedule a check that only runs once or twice a second. (There is an entire scheduling system he isn't using, either)

It's also worth noting that there's no need to rely on the position of the character for any of this logic. There is a method to get the position of a sprite (the tile) relative to the "screen" which would work just fine.

I hope you are starting to get a grasp for just how deep of a hole this guy dug himself. None of the things he did are easily decoupled.

a nest of hornets fucked around with this message at 16:23 on May 4, 2013

Wheany
Mar 17, 2006

Spinyahahahahahahahahahahahaha!

Doctor Rope


Thanks, Adobe, for telling me that my first name cannot contain characters it contains (a hyphen).

Foiltha
Jun 12, 2008
I'm sort of impressed by that iPad guy. He's probably committed more lines for that project than I have in my entire life :v:

Volmarias
Dec 31, 2002

EMAIL... THE INTERNET... SEARCH ENGINES...

FOLLOW ME BRUH posted:

This was the most recent commit. I can't tell if he's learned something over the 9 months he's been doing this, or he's just run out of steam.



:wtf:
:lol: 20k lines added, 15k removed
30k lines added :supaburn:

This is strangely familiar, almost as if a coworker does the same thing and I repeatedly bang my head against a wall trying to make him write good messages.

The only reason we get any good messages now is because we use Gerrit and won't accept his patches if he can't give a reasonable message. Otherwise, we'd get the same 20k lines "fixed" messages.

seiken
Feb 7, 2005

hah ha ha
How the gently caress do you make 20K line commits, I don't even get it. Is he just doing huge find+replaces all over the project or what, I don't know.

nielsm
Jun 1, 2009



seiken posted:

How the gently caress do you make 20K line commits, I don't even get it. Is he just doing huge find+replaces all over the project or what, I don't know.

It's probably a case of just hacking away and pasting in giants chunks of googled code, and once a week or so remembering, "oh yeah that 'source control' poo poo they're forcing me to use..."

Doctor w-rw-rw-
Jun 24, 2008

FOLLOW ME BRUH posted:

Also something something spoiled idiots arc memory management :argh:
As someone who migrated from 'normal' to ARC - who liked pre-ARC semantics, I've gotta say that ARC is actually pretty great. Spoiled idiots would just gently caress up something else if not ARC, anyways.

FOLLOW ME BRUH posted:

Any number of ways. The most rigid, least complicated method, in this situation (because the character always moves at a static speed), is to schedule a check that only runs once or twice a second. (There is an entire scheduling system he isn't using, either)
CADisplayLink is probably useful in this instance; it'll be called as often as the device will allow. Just FYI.

Hughlander
May 11, 2005

Doctor w-rw-rw- posted:

As someone who migrated from 'normal' to ARC - who liked pre-ARC semantics, I've gotta say that ARC is actually pretty great. Spoiled idiots would just gently caress up something else if not ARC, anyways.

Wish I could migrate. 1/2 million LoC and 4.3 is still a supported platform.

Volmarias
Dec 31, 2002

EMAIL... THE INTERNET... SEARCH ENGINES...

nielsm posted:

It's probably a case of just hacking away and pasting in giants chunks of googled code, and once a week or so remembering, "oh yeah that 'source control' poo poo they're forcing me to use..."

Yes, this. There are many source control sins of this developer, but the worst is that he works on multiple things simultaneously, so a patch will have a feature and maybe part of another.

Put it in another patch? Nah, just comment it out with "uncomment later when ready" as a comment next to it.

Doctor w-rw-rw-
Jun 24, 2008

Hughlander posted:

Wish I could migrate. 1/2 million LoC and 4.3 is still a supported platform.

500kloc? What the heck are you building? :aaa:

a nest of hornets
Nov 17, 2012

by Ralp

Foiltha posted:

I'm sort of impressed by that iPad guy. He's probably committed more lines for that project than I have in my entire life :v:

Don't be fooled. When I said his "submodule game is insane", I mean that he didn't have any. So 99% of that is cocos2d-iphone and box2d (physics engine).

Typically you would want to have each of these frameworks/libraries coming in from their own submodule. It makes doing things like updating the game to use a newer version of the engine a bit less insane.

A lot of people prefer to leave assets out of source control entirely, usually because it causes the size of the repo to explode, and scribblers (designers) are easily confused. Generally, these people haven't seen git-annex, which lets you do things like limit the amount of copies you keep in the repo on a per file or filetype basis, amongst other fancy things. (no windows support, though)

Volmarias posted:

The only reason we get any good messages now is because we use Gerrit and won't accept his patches if he can't give a reasonable message. Otherwise, we'd get the same 20k lines "fixed" messages.

It's so bewildering to me that some people will literally never do this unless they are absolutely forced to. Shoutout to every dev still out there using a folder full of project.backup.old(1).zip's

seiken posted:

How the gently caress do you make 20K line commits, I don't even get it. Is he just doing huge find+replaces all over the project or what, I don't know.

The entire codebase is an interconnected mess. He's also using a few "game development utilities" to generate large chunks of code for him, only, he also used those tools incorrectly, so they make much bigger messes than they need to.

nielsm posted:

It's probably a case of just hacking away and pasting in giants chunks of googled code, and once a week or so remembering, "oh yeah that 'source control' poo poo they're forcing me to use..."

Volmarias is spot on, this kind of 'scourge-control' effectively negates the point of using git in the first place!

These commits are on average, 2 months apart from one another. Those are over the span of 9 months. But yes, the entire project is googled code. The helloWorldScene from the example project can still be found in the root of the project. :doh:

Doctor w-rw-rw- posted:

As someone who migrated from 'normal' to ARC - who liked pre-ARC semantics, I've gotta say that ARC is actually pretty great. Spoiled idiots would just gently caress up something else if not ARC, anyways.

CADisplayLink is probably useful in this instance; it'll be called as often as the device will allow. Just FYI.

I'm not saying I have any problems with ARC myself, moreso that were it not for ARC, this idiot would not have lasted 3 days, let alone 3 or 9 months.

As far as intimidating non-ARC codebases go: at my last FTE, we had our own protocol suite for use in an iOS framework that does a bunch of MFi/BTLE/4G stuff. Part of this included running an embedded http server within every application that uses the framework, with extensive backgrounding/url-scheme/networking trickery to do some crazy poo poo. I can't really go into it much further past that, but it was all store-kosher. I learned and forgot a lot about networking/sockets. That was ~250k LOC of mixed C/C++/ObjC wrappers.

Fighting to not support retarded iOS versions is probably one of the unexpected hardships of iOS development. It's extremely dependent on the target market. Getting the client to agree to set the target to iOS 6, up from 4.3, was like pulling teeth… even though the launch date isn't until sometime in 2014 :psyduck:

I'm not sure what you intend for me to do with CADisplayLink? Cocos2d abstracts most of what you would have to do in a typical runloop away, when I say 'runloop', I mean he's stuffing this poo poo in the -(void)tick:(float)dt method of the scene. Cocos2d provides its own scheduler and all that. You don't /have/ to use it, but it's good enough most of the time.

I just went and double-checked, riq added CADisplayLink support back around after it was introduced, in iOS 3.1, for cocos2D 0.8 or so (we are on version 2 now)

Edit: Holy massive post batman. Not sorry.

Two more things:

1) Can't you use ARC on iOS 4 with the exception of weak references? Which I think you can replace with unsafe_unretained?

2) Here's a video of the only bug that I was able to fix, before I fixed it. Sorry for portrait. Cause of this bug? Using terribad default box2d engine settings. Changed 2 numbers and looked like a hero. What you won't hear me talking about, are the 3 days of spelunking I had to do to come to the realization that nothing was configured correctly.

C) I'm really excited for iOS7/WWDC.

a nest of hornets fucked around with this message at 22:03 on May 4, 2013

QuarkJets
Sep 8, 2008

How do these people manage to get programming jobs without the skills that the jobs require?

a7m2
Jul 9, 2012


They probably know enough theory to tell non-IT clients an impressive sales-pitch. If you've got a company and you're looking for your first IT expert, it's very hard to see what people are competent and what aren't.

pokeyman
Nov 26, 2006

That elephant ate my entire platoon.

Hughlander posted:

Wish I could migrate. 1/2 million LoC and 4.3 is still a supported platform.

Hopefully you already know these two things, but just in case: you can opt in to (or out of) ARC on a per file basis; and PLWeakCompatibility's got your back for iOS 4.

a nest of hornets
Nov 17, 2012

by Ralp

QuarkJets posted:

How do these people manage to get programming jobs without the skills that the jobs require?

I found his github. He's one of those people that fork 20 repos, and does nothing to any of them. Recruiters interpret this as activity/quality :doh:

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe
Ah, that's why I have so many nothing-forks of my actual projects on GitHub.

The Gripper
Sep 14, 2004
i am winner

substitute posted:

Sony is awesome. I had set the PS3 to ask for the password before PSN purchases, so for the past few weeks the store was asking for my password even when I hit the download buttons on free demos. I input random characters every single time and the download would start. I never tested an actual credit card purchase.

Why even prompt for it on free stuff, and then not even verify? Stupid program flow.
PSN is just broken in a ton of ways. A few days ago I purchased a pre-order and added funds to my wallet to cover it, and ended up with this email chain:

It then immediately withdrew cash from my credit card to cover the purchase anyway, so I've got $50 sitting in my PSN wallet for no reason.

(plus the game I pre-ordered got it's date pushed back anyway, so the charge was about a week early <:mad:>).

Edison was a dick
Apr 3, 2010

direct current :roboluv: only

FOLLOW ME BRUH posted:

A lot of people prefer to leave assets out of source control entirely, usually because it causes the size of the repo to explode, and scribblers (designers) are easily confused. Generally, these people haven't seen git-annex, which lets you do things like limit the amount of copies you keep in the repo on a per file or filetype basis, amongst other fancy things. (no windows support, though)

A friend of mine is a good friend of the creator of git-annex, so I hear about it a lot.

Windows support is planned as part of the Kickstarter. He sounds nearly done on the Android port, so you may have good news on this front soon.

a nest of hornets
Nov 17, 2012

by Ralp

Suspicious Dish posted:

Ah, that's why I have so many nothing-forks of my actual projects on GitHub.

The best part? The recruiters are completely oblivious to the fact that I've forked HTML5 as a joke. Must be a guru.

Edison was a dick posted:

A friend of mine is a good friend of the creator of git-annex, so I hear about it a lot.

Windows support is planned as part of the Kickstarter. He sounds nearly done on the Android port, so you may have good news on this front soon.

Looks like it's already funded! Are there alternative ways to give him money in the meantime?

Edison was a dick
Apr 3, 2010

direct current :roboluv: only

FOLLOW ME BRUH posted:

Looks like it's already funded! Are there alternative ways to give him money in the meantime?

He already seems well funded, though if you're looking for a blog or wiki you can manage as a Git repository, you could get a Branchable page.
I'm sure he'd appreciate an email of support.

Oh, and rather than being nearly done, it looks like the Android version was finished a couple of days ago.

Admiral H. Curtiss
May 11, 2010

I think there are a bunch of people who can create trailing images. I know some who could do this as if they were just going out for a stroll.
Someone clearly didn't understand/know of proper sprintf usage here.

code:
unsigned long int n0=0,n1=0,n2=0,n3=0;

[...]

for (i=0;i<numpoint-1;i++)
{
	[...]

	sprintf(name,"%d%d%d%d.dat\0",n0,n1,n2,n3);

	if (n3==9)
	{
		n3=0;
		n2=n2+1;
	}else{
		n3=n3+1;
	}
	if (n2==10)
	{
		n2=0;
		n1=n1+1;
	}
	if (n1==10)
	{
		n1=0;
		n0=n0+1;
	}
}

Adbot
ADBOT LOVES YOU

Volmarias
Dec 31, 2002

EMAIL... THE INTERNET... SEARCH ENGINES...
Edit: nevermind

Volmarias fucked around with this message at 17:03 on May 5, 2013

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply