Backup NOW!

Miscellaneous Forums/General Discussion/Backup NOW!

A call to DrawPrimitive() (DX7 API) with a mistakenly 0 sized bank rebooted my PC. After rebooting all my open documents in Visual Blitz IDE were blank, all 10 of them.

Strangely the file sizes are the same, they're all just completely zeroed out, freaky!

My backups are only 4 days old, but still, lesson learned. It doesn't take a dying HD to lose your work.

Interesting. Running any alpha/beta version graphics drivers or anything?

No, same old ATI 6.something I've had for ages.

There's another DX7 function that reboots if you give it bad values, settexturestagestate(index,D3DTSS_COLOROP,op), if op <1 or >24, boom!

I ran a disk explorer type program, the files are indeed just zeroes now, never had anything like that happen before.

I've had the same problem!!!! I have no clue how that happened... Could it be DX7TEST????

:P

Might I recommend Subversion?

I ran a disk explorer type program, the files are indeed just zeroes now, never had anything like that happen before.

I once had a fiasco that took this to a higher level.

It was back in the days of floppy disks and I was doing some assembly language programming. While testing my program there was some unexpected drive activity which lasted several seconds.

After that I couldn't see any files on the floppy disk. A sector editor program showed that the File Allocation Table consisted entirely of zeroes. All the data was still on the disk, but totally worthless. With no information on how to match up sectors with files the data is just a meaningless jumble.

A sector editor program showed that the File Allocation Table consisted entirely of zeroes.

Reminds me of when I was playing around with the debug program for MSDOS, and accidently destroyed the MBR.
debug, poor understanding of assembly and trying to read a file from disk = bad idea.

_33: DX7TEST is my work, but it's not the DLL, it's calling DX7 Functions with unsafe values.

As I said about settexturestagestate(index,D3DTSS_COLOROP,op), passing anything <1 or >24 for 'op' reboots my PC. Pass defined Consts only that way you're safer.

I'm having a little luck recovering some files, it seems the code is there on my HD, fully intact too. But it's slow searching.

guys...


this has happenhed with B3D since the very first editions, even the auto-created backup files would be nullified- and this was with straight B3D with its own IDE.

I'm surprised you've only just noticed this Tom- I always kept a backup of the last stable source in a new folder.

I kept undelete software on a seperate drive and it's usually able to recover the files.

I'm getting the files back but slowly. It aint like they've been deleted, more like a new file of the same size has been created, filled with nothing, and the old files 'body of code' just left wandering on my HDs blocks somewhere.

I'm only finding stuff by doing keyword searches of unique function/var names which I've had to try and remember!

In a few code samples I've put the name of the file at the top of the code, I've found those ones quickly (a good habit me thinks!)

I've never had default or Visual Blitz IDEs crash & burn like this, I'm confident my reboot was caused by a few DX7 API calls with out of range values. I guarantee with all the messing in DX I've done that it aint the first time I've passed bad values, but usualy the function just returns an error, not a kick in the nads like this :P

Well, the cause of the crash is irrelevant really, My crashes were caused by a system fault- the problem is that if it crashes after you press f5 but before it finished writing to the disk, it seems to put an incorrect file pointer in the NTFS version of the FAT table (sorry- I only know FAT ;) )

Its odd that your undelete software was unable to recover by filename, i've always been able to use undelete professional to do just that, and I was done within half hour.

Still, its a sigh of relief when its done, so i'm glad youre having success!

[edit]

What did you do, DX7_SetgraphicsMemoryClockSpeed(-1)? XD

even the auto-created backup files would be nullified- and this was with straight B3D with its own IDE.
When and where are these backup files created? I've never been able to locate them. :/

when you save/run a B2D/B3D program in its own IDE, it creates a .BB_BAK<n> file. these are also nullified in the above error making them useless.

That's odd, I use the default IDE and have never seen one of these bak files. Are they supposed to be created in the same folder as the original .bb file?

big10p: I think it stores them in the 'tmp' folder, there's a setting in 'blitz.prefs' to specify how many levels of backup.

Cygnus: The thing is, I had about 10 files open in my IDE, I was only running 1 of them, but all 10 were wiped, NOT deleted! The files stayed exactly the same size on disk, just completely blank.

yeah, when you hit f5 the IDE will save *all*. its the disk caching that actually causes the corruption.

I see the BB_BAK files in the same folder as the original BB files. :P

Anyway, I dont use BB anymore.

Ah-ha! Yes, there's an 'edit_backup' setting. Mine was set to 0, for some reason - maybe that's the deafult?! Anyway, I set it to 1 and now I get bak files created in the same folder as the original source. :)

See, that's why I love Blitz3D - I never get my hands dirty. Actually I had only a few crashes with Blitz3D through the past years.

What Noel said.

heh i missed Noels post- SVN is a great tool. I didnt use it until recently and I can tell you I pretty much couldn't live without it now. :D

www.mozy.com