News:

When registered with our forums, feel free to send a "here I am" post here to differ human beings from SPAM bots.

Main Menu

Possible bug in $ACTIVE_EDITOR_FILENAME

Started by cichmen, June 17, 2009, 08:08:14 PM

Previous topic - Next topic

cichmen

Hi,

I have experienced odd behaviour of $ACTIVE_EDITOR_FILENAME built-in. I'm using it in post-build step.

- Open file "file1.c" in editor, do rebuild, the built-in is right = "file1.c"
- close file "file1.c", open "file2.c" in editor, do rebuild, the build-in contains still "file1.c", but should contain "file2.c"

Any advice?

Thanks,
C.

killerbot

thanks for the feedback, can you also file this issue in our bug tracker on our berlios page ?
So it doesn't get lost ..

Jenna

I just tried it with a simple test project and cannot reproduce this behaviour.

Which OS and which version of C::B do you use ?

Can you provide a simple test-project whre this behaviour occurs ?

cichmen

I'm using Release 8.02, on XP SP2.

Important to reproduce is the order:
1) Open only "file1.c" in editor, do rebuild
2) Close "file1.c"
3) Open only "file2.c" in editor, do rebuild

I'm not able to attach file (3kB) to this discussion, it says  "The upload folder is full. Please try a smaller file and/or contact an administrator".

killerbot

could you try to download the latest nightly (see nightly builds section in the forum).
Those are also very stable and up to date.

Jenna

I can confirm this bug, and it is fixed in trunk (r5654).

We only recalced the name of the active editor, if the pointer to the editor has changed.
Normally perfectly legal, but in some cases, if nothing else changed the calling new cbEditor(... allocated the same memory as before, so the macrosmanager was unable to detect that the editor has changed.
It now checks if the name of the file associated with the editor has changed.

cichmen