Author Topic: Error Saving Files  (Read 20982 times)

Offline lehe

  • Multiple posting newcomer
  • *
  • Posts: 35
Error Saving Files
« on: February 03, 2009, 09:28:42 am »
I have two systems on my laptop: Windows XP and Ubuntu 8.10
My CB svn5432 is in Ubuntu. My program is saved in the hard drive of Windows and can be accessed from Ubuntu.
Before yesterday everything is fine. Since then, any change to my program under CB always fail to proceed, giving an Error Saving Files message window saying "File ... could not be saved...". If I copy my program to the part of hard drive for Ubuntu, then change to the copy can be saved. And any change to my program made under gedit and other editors can be saved. How can I fix this problem in CB? Thanks!
« Last Edit: February 03, 2009, 09:56:37 am by lehe »

Offline dje

  • Lives here!
  • ****
  • Posts: 683
Re: Error Saving Files
« Reply #1 on: February 03, 2009, 09:48:38 am »
Hi!

I have no answer but I think your C::B version will help devs that can help you.

Dje

Offline lehe

  • Multiple posting newcomer
  • *
  • Posts: 35
Re: Error Saving Files
« Reply #2 on: February 03, 2009, 09:54:42 am »
Mine svn 5432

Offline jens

  • Administrator
  • Lives here!
  • *****
  • Posts: 7265
    • Jens' unofficial debian-repository for the Code::Blocks - IDE
Re: Error Saving Files
« Reply #3 on: February 03, 2009, 10:06:10 am »
How much disk-space is free, when the error occurs?

How large are the files ?

Do you have any *.cbTemp-files in the directory after the saving does not work ?

Did the error started when after updating C::B, or does it start with a version, that worked before?

Offline lehe

  • Multiple posting newcomer
  • *
  • Posts: 35
Re: Error Saving Files
« Reply #4 on: February 03, 2009, 03:04:49 pm »
I think my disk is still plentifully free. Root is just used 54% with total 7.3G, home 6% with 5.5G, Windows C drive 64% with 45G (FAT32) and Windows D drive 75% with 31.3G (NTFS). Windows D drive is where my program is stored.

I have tried some programs. The files of my program can be as small as one C file of size 1.1KB and as big as 55 header and source files of total size 123.9KB

I do have some *.cbTemp-files in the same directory for the file I failed to make change to. Looks like my change was stored in these temporary files and failed to write into my code file. Does it mean something?

I didn't quite notice this happened along with the upgrade. But I remembered with 8.02, there was no such problem. Then I upgraded to svn5382 and subsequently to svn5432. It seems to me the problem came around 5382.

Thanks!
« Last Edit: February 03, 2009, 03:32:38 pm by lehe »

Offline jens

  • Administrator
  • Lives here!
  • *****
  • Posts: 7265
    • Jens' unofficial debian-repository for the Code::Blocks - IDE
Re: Error Saving Files
« Reply #5 on: February 03, 2009, 04:10:49 pm »
Is the original-file unchanged, or is it cleared ?

If it is unchanged, you most likely do not have write-access to the file (not the file-system).

I'm not sure if writing to ntfs-partitions from linux works reliable in the meantime.

I still use FAT32-partitions for shared filesystems.

The filemanager-code (where the tempfile is created and the original file should be overwritten) is not changed since revision 5104, so the error is most likely a problem with access-rights.

Offline lehe

  • Multiple posting newcomer
  • *
  • Posts: 35
Re: Error Saving Files
« Reply #6 on: February 03, 2009, 05:58:41 pm »
Thanks!
What does it mean "Is the original-file unchanged, or is it cleared ?"
If I try to modify the content of my code file, the file appears to be changed, but attempts to save fails leaving a "*" on the tab of the file in CB editor. At the meantime, the .cbTemp file for my code file is created under the same directory to store the version before my modification. After I force to quit CB without saving, the .cbTemp file remains where it was.

The problem didn't happen with other editors, like gedit.
« Last Edit: February 03, 2009, 06:05:00 pm by lehe »

Offline jens

  • Administrator
  • Lives here!
  • *****
  • Posts: 7265
    • Jens' unofficial debian-repository for the Code::Blocks - IDE
Re: Error Saving Files
« Reply #7 on: February 03, 2009, 06:43:30 pm »
Thanks!
What does it mean "Is the original-file unchanged, or is it cleared ?"

I wanted to know, whether you have an empty file or just an unchenged one, if you open it with another editor.

But what's about the file permissions and odes it happen on any other partition, or only on the ntfs-partition ?

Offline lehe

  • Multiple posting newcomer
  • *
  • Posts: 35
Re: Error Saving Files
« Reply #8 on: February 03, 2009, 07:15:42 pm »
If opened with gedit, it is unchanged just as it was, not empty.

On my Windows FAT32 disk, which is also my Windows system disk, when I create a new project, I got this error "Couldn't save project /windows-c/opencv/helloworld_linux/helloworld_linux.cbp (Maybe the file is write-protected?)". Subsequently saving changes to the code files fails. The same thing happens to my Windows NTFS disk.

« Last Edit: February 03, 2009, 10:09:30 pm by lehe »

Offline jabahpureza

  • Single posting newcomer
  • *
  • Posts: 2
Re: Error Saving Files
« Reply #9 on: March 04, 2010, 08:39:45 pm »
I've got the exactly same problem here.

When I open a saved project from a NFTS partition I can't save any change! For every file I change and try to save I get this "Error Saving Files" window.
When I copy the same project to a GNU/Linux partition I can save it normally.

But when I run code:blocks as root "gksudo codeblocks" this problem disappears.

Is it a code::blocks bug or what?

thank you very much!
jjR

Online stahta01

  • Lives here!
  • ****
  • Posts: 6666
    • My Best Post
Re: Error Saving Files
« Reply #10 on: March 04, 2010, 10:33:22 pm »
I've got the exactly same problem here.

When I open a saved project from a NFTS partition I can't save any change! For every file I change and try to save I get this "Error Saving Files" window.
When I copy the same project to a GNU/Linux partition I can save it normally.

But when I run code:blocks as root "gksudo codeblocks" this problem disappears.

Is it a code::blocks bug or what?

thank you very much!
jjR

The above is the example of a permission problem.

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 32 bit.
On Debian Stretch, compiling CB Trunk against wxWidgets 3.0.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline schizofrenikh

  • Single posting newcomer
  • *
  • Posts: 6
Re: Error Saving Files
« Reply #11 on: March 29, 2011, 09:09:35 pm »
I think the problem is here
https://bugs.launchpad.net/ubuntu/+source/ntfs-3g/+bug/124795?comments=all
I posted a comment in the bottom because this is how i suppose the problem looks like.
Am I right about the CodeBlocks trying to change the modification time? Or is it trying to do some other not really necessary operation on the file which gedit doesn't try to do?

Offline jens

  • Administrator
  • Lives here!
  • *****
  • Posts: 7265
    • Jens' unofficial debian-repository for the Code::Blocks - IDE
Re: Error Saving Files
« Reply #12 on: March 29, 2011, 09:43:27 pm »
I think the problem is here
https://bugs.launchpad.net/ubuntu/+source/ntfs-3g/+bug/124795?comments=all
I posted a comment in the bottom because this is how i suppose the problem looks like.
Am I right about the CodeBlocks trying to change the modification time? Or is it trying to do some other not really necessary operation on the file which gedit doesn't try to do?
It's not C::B itself, but the wxWidgets function it uses:
http://forums.codeblocks.org/index.php/topic,10735.msg73563.html#msg73563
http://forums.codeblocks.org/index.php/topic,10263.msg70971.html#msg70971

Offline schizofrenikh

  • Single posting newcomer
  • *
  • Posts: 6
Re: Error Saving Files
« Reply #13 on: March 30, 2011, 10:46:01 am »
Thank you for reply.

Well, now I will try searching at wxWidgets forums. Maybe they have found some solution.