LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 10-06-2004, 05:26 PM   #1
dizzutch
Member
 
Registered: Sep 2004
Location: Worcester, MA USA
Distribution: Debian, Gentoo, Fedora FC2
Posts: 66

Rep: Reputation: 15
strange file creation problem


Hey all,
I'm trying to do some manipulation to bitmaps, which works fine, but when i try to export the created bitmap to disk, say to file morph000.bmp the file created will be morph000.bmpi? (including the questionmark) I'm really not sure what causes this error.
any ideas are appreciated.
Thanks!
-JSS

Code:
    if (disk_save)  {
      filename = (char*)malloc(10*sizeof(char));
      sprintf(filename,"morph%03d.bmp", t);
      SaveDIBitmap(filename, Bitmap1Info,  buffer[t]);
    }
SaveDIBitmap()
Code:
 if ((fp = fopen(filename, "wb")) == NULL)
        return (-1);
  ...
  fclose(fp)
 
Old 10-06-2004, 05:30 PM   #2
dizzutch
Member
 
Registered: Sep 2004
Location: Worcester, MA USA
Distribution: Debian, Gentoo, Fedora FC2
Posts: 66

Original Poster
Rep: Reputation: 15
never mind, not allocating enough space..duh

-JSS
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Strange vsftpd problem concerning file transfer 0p3r4 Linux - General 2 11-24-2005 12:26 AM
Core file creation problem on ramdisk system hasse69 Linux - General 1 05-12-2005 03:06 PM
php read file creation, modified date problem antony_csf Programming 3 08-18-2004 06:46 AM
Apache File Permission Strange Problem hcubed Linux - Networking 1 05-15-2004 01:09 AM
RPM Spec file creation: %file section question davidas Linux - Newbie 0 03-16-2004 10:36 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 09:11 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration