mirror of
https://github.com/puma/puma.git
synced 2022-11-09 13:48:40 -05:00
Updated ServiceFB to r80 to solve issues when compiling with FB > 0.17.
git-svn-id: svn+ssh://rubyforge.org/var/svn/mongrel/trunk@583 19e92222-5c0b-0410-8929-a290d50e31e9
This commit is contained in:
parent
2eaecba2ff
commit
5261461b3d
6 changed files with 21 additions and 5 deletions
|
@ -1,3 +1,9 @@
|
|||
* SVN *
|
||||
|
||||
* Properly display package/gem version for mongrel_service. Closes #13823.
|
||||
|
||||
* Updated ServiceFB to r80 to solve issue when compiling with FB > 0.17.
|
||||
|
||||
* 0.3.2 *
|
||||
|
||||
* Solved detection of parent process at ServiceFB level
|
||||
|
|
|
@ -39,7 +39,7 @@ setup_rdoc ['README', 'LICENSE', 'COPYING', 'lib/**/*.rb', 'doc/**/*.rdoc']
|
|||
desc "Does a full compile, test run"
|
||||
task :default => [:compile, :test]
|
||||
|
||||
GEM_VERSION = "0.3.2"
|
||||
GEM_VERSION = "0.3.3"
|
||||
GEM_NAME = "mongrel_service"
|
||||
|
||||
desc "Compile native code"
|
||||
|
|
|
@ -163,6 +163,13 @@ namespace svc
|
|||
end sub
|
||||
|
||||
|
||||
'# call_onStart() is a wrapper around the new limitation of threadcreate
|
||||
'# sub used as pointers in threadcreate must conform the signature
|
||||
sub ServiceProcess.call_onStart(byval any_service as any ptr)
|
||||
var service = cast(ServiceProcess ptr, any_service)
|
||||
service->onStart(*service)
|
||||
end sub
|
||||
|
||||
'#####################
|
||||
'# ServiceHost
|
||||
'# ctor()
|
||||
|
@ -336,7 +343,7 @@ namespace svc
|
|||
service->UpdateState(SERVICE_RUNNING)
|
||||
if not (service->onStart = 0) then
|
||||
_dprint("dispatch onStart() as new thread")
|
||||
service->_threadHandle = threadcreate(service->onStart, service)
|
||||
service->_threadHandle = threadcreate(@ServiceProcess.call_onStart, service)
|
||||
'# my guess? was a hit!
|
||||
end if
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
'# See MIT-LICENSE file for details
|
||||
'#++
|
||||
|
||||
#if __FB_VERSION__ <> "0.17"
|
||||
#if __FB_VERSION__ < "0.17"
|
||||
#error ServiceFB is designed to compile with FreeBASIC version "0.17"
|
||||
#else
|
||||
|
||||
|
@ -62,6 +62,9 @@ namespace svc '# fb.svc
|
|||
onPause as sub(byref as ServiceProcess)
|
||||
onContinue as sub(byref as ServiceProcess)
|
||||
|
||||
'# call_* are used to avoid the warning arround ThreadCreate
|
||||
declare static sub call_onStart(byval as any ptr)
|
||||
|
||||
'# properties (public)
|
||||
name as string
|
||||
description as string
|
||||
|
|
|
@ -188,7 +188,7 @@ namespace utils '# fb.svc.utils
|
|||
'# now, fire the main loop (onStart)
|
||||
if not (service->onStart = 0) then
|
||||
'# create the thread
|
||||
working_thread = threadcreate(service->onStart, service)
|
||||
working_thread = threadcreate(@ServiceProcess.call_onStart, service)
|
||||
end if
|
||||
|
||||
print "Service is in running state."
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
'# See MIT-LICENSE file for details
|
||||
'#++
|
||||
|
||||
#if __FB_VERSION__ <> "0.17"
|
||||
#if __FB_VERSION__ < "0.17"
|
||||
#error ServiceFB is designed to compile with FreeBASIC version "0.17"
|
||||
#else
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue