Moderator: Spunkmeyer
my $fh = CRopen(">$file");
print $fh "something";
close($fh);
sub CRclose ($) {
my $filehandle = shift;
close ($filehandle) or CRdie('Some Error Message');
}
my $fh = CRopen(">$file");
print $fh "something";
CRclose($fh);
Could you please let me know in which thread you found the fix, maybe this is something that should be included into the core? And what does the message say exactly when this happens?Pirate Elf wrote:the exact error page actually shows now thanks to a small line of code i found in another thread that basically tells me there is a problem with Xnewstopic.txt instead of just a blank page or worse
I think it is the other way arround actually, the blank profile is created first for some reason and since it probably have the same settings as one of the other normal profiles it is writing to the same file as that one which makes Coranto end up in a dead lock as I described above. I remember vaguely that we have had issues with "shadow/blank profiles" before, I will try and do a little searching. Could you please post exactly your setup; version of Coranto and version of the addons you use?Pirate Elf wrote:Third Go to partial rebuild and find the blank profile (Why does it make a
blank profile when all the xnews.txt files go 0 I have no clue but it does)
Good idea! I will add this sub into Coranto 1.31.x and make all internal close calls in Coranto use that sub instead, but it will be hard for addons to really take advantage of this new sub since the addon must work in older setups as well...faithless wrote:My suggestion for Coranto is, to instead of using the close($fh) statement, to implement a CRclose wrapper to catch file closing errors similar to this:
- Code: Select all
sub CRclose ($) {
my $filehandle = shift;
close ($filehandle) or CRdie('Some Error Message');
}
Parahead wrote:Could you please let me know in which thread you found the fix, maybe this is something that should be included into the core? And what does the message say exactly when this happens?
Parahead wrote:I am guessing now, but do you use the headlines feature in some profiles? If so, could you try change the headline part in those to be a new normal profile instead? It could be something there in conjuction with the Partial Rebuild addon.
Aha, OK. This really tells me that it is a file lock issue and not space problem anyway... And yes, this is indeed included in the 1.31.x release.Pirate Elf wrote:I can't remember exactly but you were the one that gave me the snippet so more than likely it is already in the new core. All it does is show an error screen with what went wrong when you do a full rebuild instead of a just a blank page. ie "Failed to open news.txt at path/blah" (AHAHA found it: Fix
Great, let me know what you find out...Pirate Elf wrote:Yes, will toy with it after work and see what I come up with.
Return to Addon Development and Requests
Users browsing this forum: No registered users and 2 guests