Search found 62 matches
- Tue Sep 24, 2019 10:50 am
- Forum: Linux
- Topic: Import SYSLOG - Pseudotype bug/error?
- Replies: 1
- Views: 2887
Re: Import SYSLOG - Pseudotype bug/error?
I know it's a bit late, but i found and used your code. Setting ident does do weird stuff so i just ignored it. Here's my take on this. ; C header for syslog (GNU C utils) ; option flags for openlog #Syslog_PID = $01 ;log the pid with each message #Syslog_CONS = $02 ;log on the console if errors in ...
- Tue Feb 05, 2019 10:21 am
- Forum: Feature Requests and Wishlists
- Topic: Hardcoded PureBasic.dll
- Replies: 11
- Views: 3687
Re: Hardcoded PureBasic.dll
Sorry, I think that is a contradiction to what it reads on the page that you mentioned: Examples: CLI> pbcompiler "C:\Project\Source\DLLSource.pb" /EXE "C:\Project\project.dll" /DLL The compiler will compile the source code (here with full path) and create the DLL "project....
- Tue Feb 05, 2019 10:17 am
- Forum: Feature Requests and Wishlists
- Topic: Hardcoded PureBasic.dll
- Replies: 11
- Views: 3687
Re: Hardcoded PureBasic.dll
Yes, you can use the /EXE flag to specify the output name. I agree it's badly named, it should be /OUTPUT parameter. Great, that works for me to know that now. :) I think changing /DLL: Create a DLL to /DLL "Filename": Create a DLL with the given file name. would be the easiest to grasp i...
- Mon Feb 04, 2019 10:35 am
- Forum: Feature Requests and Wishlists
- Topic: Hardcoded PureBasic.dll
- Replies: 11
- Views: 3687
Hardcoded PureBasic.dll
Is there a reason that DLLs must be named PureBasic.dll on Windows?
In the past i simply renamed it afterwards, but now i'm actually trying to link to it and the linker insists on linking to PureBasic.dll.
In the past i simply renamed it afterwards, but now i'm actually trying to link to it and the linker insists on linking to PureBasic.dll.
- Thu Jul 12, 2018 3:53 pm
- Forum: Coding Questions
- Topic: JSON merge
- Replies: 5
- Views: 1658
Re: JSON merge
So in the absence of merge functionality i created a clone function. This is obviously not performant, but ok for small stuff. Procedure jsonClone(jSrc, jDest) Select JSONType(jSrc) Case #PB_JSON_Null: SetJSONNull(jDest) Case #PB_JSON_String: SetJSONString(jDest, GetJSONString(jSrc)) Case #PB_JSON_N...
- Thu Jul 12, 2018 11:51 am
- Forum: Coding Questions
- Topic: JSON merge
- Replies: 5
- Views: 1658
JSON merge
How do i merge 2 JSON objects, so that one is a sub object of the other? Example: top = ParseJSON(#PB_Any, ReplaceString("{'foo':'bar','test':1}", "'", Chr(34))) sub = ParseJSON(#PB_Any, ReplaceString("{'prop1':'val1','test1':1, 'more':{ 'a':1, 'b': 'hi'}}", "'&quo...
- Wed Nov 11, 2015 4:41 pm
- Forum: General Discussion
- Topic: SetFileDate Timezone
- Replies: 2
- Views: 1385
Re: SetFileDate Timezone
To add to the madness, on Windows Get and SetFileDate hold true as noted above. initial 1427594400 initial formatted 2015-03-29 02:00:00 retrieved 1427594400 retrieved formatted 2015-03-29 02:00:00 But the actual file date in the explorer is 2015-03-29 03:00:00 I never thought setting a file date co...
- Wed Nov 11, 2015 10:10 am
- Forum: General Discussion
- Topic: Shouldn't this trigger a compiler error?
- Replies: 24
- Views: 4121
Re: Shouldn't this trigger a compiler error?
The issue is not whether the variable is defined or not, but rather whether it is in the expected state. The problem with this is that it leads to potentially hard to find runtime bugs. One could argue that it is the programmers fault. I agree. Programmers do screw things up. That is why one of the ...
- Mon Nov 09, 2015 3:05 pm
- Forum: General Discussion
- Topic: SetFileDate Timezone
- Replies: 2
- Views: 1385
Re: SetFileDate Timezone
While someone could argue that 2:00-2:59 is an impossible time, then a bug in windows, the same happens for any time during summer time.
- Mon Nov 09, 2015 3:01 pm
- Forum: General Discussion
- Topic: SetFileDate Timezone
- Replies: 2
- Views: 1385
SetFileDate Timezone
I've come across peculiar behaviour with the SetFileDate function. I'm currently in Central European Time (Winter Time). The following code file.s = "/some/file" modDate = ParseDate("%yyyy-%mm-%dd %hh:%ii:%ss", "2015-03-29 01:59:59") Debug "initial " + modDate...
- Wed Aug 12, 2015 3:23 pm
- Forum: Coding Questions
- Topic: Converting from UTF-8 NFD to NFC & vice versa
- Replies: 3
- Views: 2900
Re: Converting from UTF-8 NFD to NFC & vice versa
Well, i guess it's time to answer my own post, so the result can be found also when searching decomposed to precomposed. I wrote a basic iconv wrapper specifically for this, to potentially expand on it later. It looks like this CompilerIf #PB_Compiler_OS <> #PB_OS_MacOS ImportC "" errno_lo...
- Thu Aug 06, 2015 10:26 am
- Forum: Coding Questions
- Topic: Converting from UTF-8 NFD to NFC & vice versa
- Replies: 3
- Views: 2900
Converting from UTF-8 NFD to NFC & vice versa
Hello everyone. Today, while doing a mac port, i learned that there are multiple forms of UTF-8 and that HFS+ on the mac stores it's filenames as Decomposed UTF-8 aka NFD while we generally use Precomposed UTF-8 aka NFC. The following page elaborates on this http://unicode.org/reports/tr15/#Norm_For...
- Tue May 12, 2015 12:09 pm
- Forum: Coding Questions
- Topic: how to access kCFRunLoopDefaultMode
- Replies: 6
- Views: 1671
Re: how to access kCFRunLoopDefaultMode
Thanks for your help, wilbert.
- Tue May 12, 2015 9:02 am
- Forum: Coding Questions
- Topic: how to access kCFRunLoopDefaultMode
- Replies: 6
- Views: 1671
Re: how to access kCFRunLoopDefaultMode
Ah, so if i read your post right, then it's best to just leave it alone, as there will only be one path in there for me. So resource consumption is not an issue.
- Tue May 12, 2015 8:28 am
- Forum: Coding Questions
- Topic: how to access kCFRunLoopDefaultMode
- Replies: 6
- Views: 1671
Re: how to access kCFRunLoopDefaultMode
Awesome @wilbert, you're a life saver.
Thank you
One last question. Should i
and if so can i do this right after FSEventStreamCreate, or does it need to hang around for the life time of the stream?
Thank you
One last question. Should i
Code: Select all
CFRelease(*pathsToWatch)