Go Back   Winamp Forums > Developer Center > NSIS Discussion

Reply
Thread Tools Search this Thread Display Modes
Old 8th October 2008, 14:08   #1
baxi
Junior Member
 
Join Date: Oct 2008
Posts: 4
Read right on the file

I tried your plugin and found it to be quite usefull. I have only one problem with it: the file cannot be read while it is opened via your plugin. I would suggest the to change the dwShareMode parameter in the CreateFile function at least to 1:

if(!strcmp(buf,"true"))
{
popstring(buf); // Get Second parameter from the stack (should be the log filename)
// Open an existing file and overwrite, or create a new file, without sharing
hFile=CreateFile(buf,FILE_WRITE_DATA,1,NULL,CREATE_ALWAYS,FILE_ATTRIBUTE_NORMAL,NULL);
}// else open an existing file and append, or create a new file, without sharing
else hFile=CreateFile(buf,FILE_APPEND_DATA,1,NULL,OPEN_ALWAYS,FILE_ATTRIBUTE_NORMAL,NULL);
baxi is offline   Reply With Quote
Old 8th October 2008, 14:13   #2
baxi
Junior Member
 
Join Date: Oct 2008
Posts: 4
Ooops, wrong button

I clicked the wrong button, but I don't have the right to delete the message. If an admin sees it then please delete the thread

thanks
baxi is offline   Reply With Quote
Reply
Go Back   Winamp Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off

Forum Jump