Skip to content

Commit

Permalink
Merge branch 'master' into jwi-Latest_ACE8TAO4_Micro
Browse files Browse the repository at this point in the history
  • Loading branch information
jwillemsen authored May 16, 2024
2 parents 84e9f22 + 7e73dee commit bb5fdeb
Show file tree
Hide file tree
Showing 52 changed files with 590 additions and 656 deletions.
3 changes: 3 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# These are supported funding model platforms

github: RemedyIT
16 changes: 8 additions & 8 deletions .github/workflows/gem_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
ruby: [ '2.7' ]
name: ubuntu-latest ruby-${{ matrix.ruby }}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
Expand Down Expand Up @@ -44,21 +44,21 @@ jobs:
with:
ruby-version: ${{ matrix.ruby }}
- name: checkout r2corba
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: checkout ACE_TAO
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: DOCGroup/ACE_TAO
path: ${{ env.DOC_ROOT }}
ref: Latest_ACE8TAO4_Micro
- name: checkout MPC
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: DOCGroup/MPC
path: ${{ env.MPC_ROOT }}
ref: Latest_ACE8TAO4_Micro
- name: checkout ridl
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: RemedyIT/ridl
path: ${{ env.RIDL_ROOT }}
Expand Down Expand Up @@ -101,16 +101,16 @@ jobs:
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
- uses: actions/setup-java@v3
- uses: actions/setup-java@v4
with:
java-version: ${{ matrix.java-version }}
java-package: ${{ matrix.java-package }}
architecture: 'x64'
distribution: 'zulu'
- name: checkout r2corba
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: checkout ridl
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: RemedyIT/ridl
path: ${{ env.RIDL_ROOT }}
Expand Down
18 changes: 9 additions & 9 deletions .github/workflows/linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,21 +78,21 @@ jobs:
with:
ruby-version: ${{ matrix.ruby }}
- name: checkout r2corba
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: checkout ACE_TAO
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: DOCGroup/ACE_TAO
path: ${{ env.DOC_ROOT }}
ref: Latest_ACE8TAO4_Micro
- name: checkout MPC
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: DOCGroup/MPC
path: ${{ env.MPC_ROOT }}
ref: Latest_ACE8TAO4_Micro
- name: checkout ridl
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: RemedyIT/ridl
path: ${{ env.RIDL_ROOT }}
Expand All @@ -106,7 +106,7 @@ jobs:
sudo apt-get --yes update
sudo apt-get --yes install ${{ matrix.PackageDeps }}
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
uses: github/codeql-action/init@v3
with:
languages: cpp, ruby
if: matrix.feature == 'CodeQL'
Expand All @@ -123,7 +123,7 @@ jobs:
rake test
shell: pwsh
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
uses: github/codeql-action/analyze@v3
if: matrix.feature == 'CodeQL'
jacorb:
strategy:
Expand Down Expand Up @@ -154,16 +154,16 @@ jobs:
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
- uses: actions/setup-java@v3
- uses: actions/setup-java@v4
with:
java-version: ${{ matrix.java-version }}
java-package: ${{ matrix.java-package }}
architecture: 'x64'
distribution: 'zulu'
- name: checkout r2corba
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: checkout ridl
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: RemedyIT/ridl
path: ${{ env.RIDL_ROOT }}
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,21 +31,21 @@ jobs:
with:
ruby-version: ${{ matrix.ruby }}
- name: checkout r2corba
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: checkout ACE_TAO
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: DOCGroup/ACE_TAO
path: ${{ env.DOC_ROOT }}
ref: Latest_ACE8TAO4_Micro
- name: checkout MPC
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: DOCGroup/MPC
path: ${{ env.MPC_ROOT }}
ref: Latest_ACE8TAO4_Micro
- name: checkout ridl
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: RemedyIT/ridl
path: ${{ env.RIDL_ROOT }}
Expand Down
6 changes: 3 additions & 3 deletions ext/libr2tao/orb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -85,14 +85,14 @@ class R2CSigGuard : public ACE_Event_Handler

static VALUE c_signums;
static int c_nsig;
static ACE_Auto_Ptr<ACE_SIGACTION> c_sa;
static std::unique_ptr<ACE_SIGACTION> c_sa;

static void init_ ();

CORBA::ORB_var m_orb;
bool m_signal_reactor;
ACE_Sig_Handler m_sig_handler;
ACE_Auto_Ptr<Signal> m_signal;
std::unique_ptr<Signal> m_signal;
bool m_signal_caught;
#if defined (WIN32)
R2CSigGuard* m_prev_guard;
Expand Down Expand Up @@ -867,7 +867,7 @@ VALUE rCORBA_ORB_lookup_value_factory(VALUE /*self*/, VALUE id)

VALUE R2CSigGuard::c_signums = Qnil;
int R2CSigGuard::c_nsig = 0;
ACE_Auto_Ptr<ACE_SIGACTION> R2CSigGuard::c_sa;
std::unique_ptr<ACE_SIGACTION> R2CSigGuard::c_sa;

void R2CSigGuard::init_ ()
{
Expand Down
2 changes: 1 addition & 1 deletion lib/corba.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@
# Copyright (c) Remedy IT Expertise BV
#--------------------------------------------------------------------

require 'corba/require.rb'
require 'corba/require'

include R2CORBA
17 changes: 9 additions & 8 deletions lib/corba/cbase/ORB.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,7 @@

module R2CORBA
module CORBA

module ORB

class << self
protected
def _singleton_orb_init
Expand All @@ -42,23 +40,26 @@ def self.init(*args)
a1, a2, a3 = args
if Array === a1
raise ArgumentError, "Incorrect nr. of arguments; #{args.size}" if args.size > 3

argv = a1
orb_id = (Hash === a2 ? nil : a2)
prop = (Hash === a2 ? a2 : a3)
elsif args.size == 1 || Hash === a2
raise ArgumentError, "Incorrect nr. of arguments; #{args.size}" if args.size > 2

orb_id = a1
prop = a2
else
argv = args
end
raise ArgumentError, "Invalid argument #{prop.class}; expected Hash" unless prop.nil? || Hash === prop
unless prop.nil?()
prop.inject(argv) {|a, (k, v)| a << k; a << v; a}

unless prop.nil?
prop.inject(argv) { |a, (k, v)| a << k; a << v; a }
end
@@cached_orb = CORBA::Native::ORB.init(argv.collect {|a| a.to_s }.concat(@@_default_args), orb_id.nil?() ? nil : orb_id.to_s)
@@cached_orb = CORBA::Native::ORB.init(argv.collect { |a| a.to_s }.concat(@@_default_args), orb_id.nil? ? nil : orb_id.to_s)
end
unless n_orb.nil?() || @@vf_queue.empty?()
unless n_orb.nil? || @@vf_queue.empty?
@@vf_queue.process_all { |vfklass| vfklass._check_factory }
end
@@wrapper_klass.new(n_orb)
Expand Down Expand Up @@ -98,6 +99,7 @@ def run(timeout = nil)
else
@running ||= true
raise CORBA::BAD_INV_ORDER.new('ORB has been shutdown', 0, CORBA::COMPLETED_NO) if @shutdown

while (timeout.nil? or timeout > 0) and !@shutdown
to = timeout || 0.05
f, to = self.work_pending(to)
Expand Down Expand Up @@ -158,7 +160,7 @@ def process_all(&block)
end
end

def empty?()
def empty?
f = false
synchronize do
f = @q_.empty?
Expand All @@ -180,7 +182,6 @@ def self._check_value_factory(vfklass)
def ior_map
@iormap ||= R2CORBA::IORMap.new(self)
end

end # ORB

=begin
Expand Down
10 changes: 4 additions & 6 deletions lib/corba/cbase/Request.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,7 @@
#--------------------------------------------------------------------
module R2CORBA
module CORBA

module Request

def add_in_arg(tc, val, nm = '')
self._arguments << [nm, CORBA::ARG_IN, tc, val]
self._arguments.size
Expand All @@ -35,10 +33,11 @@ def arguments

def arguments=(*args)
if args.size == 1
raise ArgumentError, 'invalid argument list' unless ::Array === args.first && args.first.all? {|a| ::Array === a }
raise ArgumentError, 'invalid argument list' unless ::Array === args.first && args.first.all? { |a| ::Array === a }

args = args.first
else
raise ArgumentError, 'invalid argument list' unless args.all? {|a| ::Array === a }
raise ArgumentError, 'invalid argument list' unless args.all? { |a| ::Array === a }
end
# clear current arguments
self._arguments.clear
Expand Down Expand Up @@ -74,6 +73,7 @@ def set_return_type(tc)

def return_value
return nil if @_rettc.nil? || @_rettc.kind == CORBA::TK_VOID || @_rettc.kind == CORBA::TK_NULL

self._return_value(@_rettc)
end

Expand Down Expand Up @@ -126,8 +126,6 @@ def _arguments
def _exceptions
@_excl ||= []
end

end

end # CORBA
end # R2CORBA
40 changes: 20 additions & 20 deletions lib/corba/cbase/Streams.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,51 +18,51 @@ def read_member(tc)
tc = tc.resolved_tc # takes care of recursive typecodes
v = case tc.kind
when TK_ANY
read_any()
read_any
when TK_BOOLEAN
read_boolean()
read_boolean
when TK_SHORT
read_short()
read_short
when TK_LONG
read_long()
read_long
when TK_USHORT
read_ushort()
read_ushort
when TK_WCHAR
read_wchar()
read_wchar
when TK_ULONG
read_ulong()
read_ulong
when TK_LONGLONG
read_longlong()
read_longlong
when TK_ULONGLONG
read_ulonglong()
read_ulonglong
when TK_OCTET
read_octet()
read_octet
when TK_FLOAT
read_float()
read_float
when TK_DOUBLE
read_double()
read_double
when TK_LONGDOUBLE
raise CORBA::NO_IMPLEMENT.new('LongDouble not supported', 0, CORBA::COMPLETED_NO)
when TK_FIXED
read_fixed()
read_fixed
when TK_CHAR
read_char()
read_char
when TK_STRING
read_string()
read_string
when TK_WSTRING
read_wstring()
read_wstring
when TK_OBJREF
read_Object()
read_Object
when TK_TYPECODE
read_TypeCode()
read_TypeCode
when TK_ARRAY, TK_SEQUENCE,
TK_ENUM, TK_STRUCT, TK_EXCEPT, TK_UNION,
TK_PRINCIPAL
read_construct(tc)
when TK_ABSTRACT_INTERFACE
read_Abstract()
read_Abstract
when TK_VALUE, TK_VALUE_BOX, TK_EVENT
read_Value()
read_Value
## TODO: TK_NATIVE
end
v
Expand Down
Loading

0 comments on commit bb5fdeb

Please sign in to comment.