Browse Source

Another Tim Blechmann patch to remove unnecessary virtual methods.

git-svn-id: http://subversion.jackaudio.org/jack/jack2/trunk/jackmp@2512 0c269be4-1314-0410-8aa9-9f06e86f4224
tags/1.90
sletz 17 years ago
parent
commit
2b0a516f73
18 changed files with 89 additions and 52 deletions
  1. +4
    -0
      ChangeLog
  2. +0
    -3
      common/JackActivationCount.h
  3. +3
    -3
      common/JackClientInterface.h
  4. +0
    -11
      common/JackConnectionManager.h
  5. +1
    -1
      common/JackLibGlobals.h
  6. +46
    -0
      common/JackPlatformChannelTransaction.h
  7. +0
    -3
      common/JackPort.cpp
  8. +0
    -1
      common/JackPort.h
  9. +1
    -1
      common/JackRequest.h
  10. +1
    -1
      common/JackServer.h
  11. +1
    -1
      common/JackServerGlobals.h
  12. +18
    -14
      common/JackShmMem.h
  13. +2
    -6
      common/JackSocket.h
  14. +4
    -2
      common/JackThread.h
  15. +1
    -1
      linux/alsa/JackAlsaDriver.cpp
  16. +1
    -1
      macosx/JackMachClientChannel.h
  17. +5
    -1
      macosx/Jackdmp.xcodeproj/project.pbxproj
  18. +1
    -2
      windows/JackWinNamedPipe.h

+ 4
- 0
ChangeLog View File

@@ -21,6 +21,10 @@ Romain Moret
Jackdmp changes log
---------------------------

2008-06-12 Stephane Letz <letz@grame.fr>

* Another Tim Blechmann patch to remove unnecessary virtual methods.

2008-06-09 Stephane Letz <letz@grame.fr>

* Improve net driver so that jack clients can be registered even if driver has not yet started.


+ 0
- 3
common/JackActivationCount.h View File

@@ -45,8 +45,6 @@ class JackActivationCount

JackActivationCount(): fValue(0), fCount(0)
{}
virtual ~JackActivationCount()
{}

bool Signal(JackSynchro* synchro, JackClientControl* control);

@@ -81,4 +79,3 @@ class JackActivationCount


#endif


+ 3
- 3
common/JackClientInterface.h View File

@@ -35,13 +35,13 @@ struct JackClientControl;
class EXPORT JackClientInterface
{

public:
public:
JackClientInterface()
{}
virtual ~JackClientInterface()
{}
virtual int Close() = 0;

virtual int ClientNotify(int refnum, const char* name, int notify, int sync, int value1, int value2) = 0;


+ 0
- 11
common/JackConnectionManager.h View File

@@ -51,9 +51,6 @@ class JackFixedArray
Init();
}

virtual ~JackFixedArray()
{}

void Init()
{
for (int i = 0; i < SIZE; i++)
@@ -138,9 +135,6 @@ class JackFixedArray1 : public JackFixedArray<SIZE>
Init();
}

virtual ~JackFixedArray1()
{}

void Init()
{
JackFixedArray<SIZE>::Init();
@@ -174,9 +168,6 @@ class JackFixedMatrix
JackFixedMatrix()
{}

virtual ~JackFixedMatrix()
{}

void Init(jack_int_t index)
{
for (int i = 0; i < SIZE; i++) {
@@ -301,8 +292,6 @@ class JackLoopFeedback
{
Init();
}
virtual ~JackLoopFeedback()
{}

void Init()
{


+ 1
- 1
common/JackLibGlobals.h View File

@@ -63,7 +63,7 @@ struct JackLibGlobals
fEngineControl = -1;
}

virtual ~JackLibGlobals()
~JackLibGlobals()
{
jack_log("~JackLibGlobals");
for (int i = 0; i < CLIENT_NUM; i++) {


+ 46
- 0
common/JackPlatformChannelTransaction.h View File

@@ -0,0 +1,46 @@
/*
Copyright (C) 2004-2006 Grame

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation; either version 2.1 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.

*/

#ifndef __JackPlatformChannelTransaction__
#define __JackPlatformChannelTransaction__

#ifdef WIN32
#include "JackWinNamedPipe.h"
#else
#include "JackSocket.h"
#endif

namespace Jack
{


/*!
\brief Channel input/output communication.
*/

#ifdef WIN32
typedef JackWinNamedPipe JackChannelTransaction;
#else
typedef JackClientSocket JackChannelTransaction;
#endif

} // end of namespace

#endif


+ 0
- 3
common/JackPort.cpp View File

@@ -43,9 +43,6 @@ JackPort::JackPort()
fTied(NO_PORT)
{}

JackPort::~JackPort()
{}

bool JackPort::Allocate(int refnum, const char* port_name, const char* port_type, JackPortFlags flags)
{
int id = GetPortTypeId(port_type);


+ 0
- 1
common/JackPort.h View File

@@ -75,7 +75,6 @@ class EXPORT JackPort
public:

JackPort();
virtual ~JackPort();

bool Allocate(int refnum, const char* port_name, const char* port_type, JackPortFlags flags);
void Release();


+ 1
- 1
common/JackRequest.h View File

@@ -22,7 +22,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#define __JackRequest__

#include "JackConstants.h"
#include "JackChannelTransaction.h"
#include "JackPlatformChannelTransaction.h"
#include <stdio.h>
#include <string.h>



+ 1
- 1
common/JackServer.h View File

@@ -66,7 +66,7 @@ class EXPORT JackServer
public:

JackServer(bool sync, bool temporary, long timeout, bool rt, long priority, long loopback, bool verbose, const char* server_name);
virtual ~JackServer();
~JackServer();

int Open(jack_driver_desc_t* driver_desc, JSList* driver_params);
int Close();


+ 1
- 1
common/JackServerGlobals.h View File

@@ -40,7 +40,7 @@ struct JackServerGlobals
static JackServer* fServer;

JackServerGlobals();
virtual ~JackServerGlobals();
~JackServerGlobals();

static bool Init();
static void Destroy();


+ 18
- 14
common/JackShmMem.h View File

@@ -57,6 +57,14 @@ class JackMem
size_t fSize;
static size_t gSize;

protected:
JackMem(): fSize(gSize)
{}

~JackMem()
{}
public:

void* operator new(size_t size)
@@ -70,12 +78,6 @@ class JackMem
free(ptr);
}
JackMem(): fSize(gSize)
{}

virtual ~JackMem()
{}

void LockMemory()
{
LockMemoryImp(this, fSize);
@@ -100,6 +102,13 @@ class EXPORT JackShmMem
protected:

jack_shm_info_t fInfo;
protected:
JackShmMem();
~JackShmMem()
{}
public:

@@ -108,11 +117,6 @@ class EXPORT JackShmMem
void operator delete(void* p, size_t size);
void operator delete(void* p);

JackShmMem();
virtual ~JackShmMem()
{}

int GetShmIndex()
{
return fInfo.index;
@@ -174,7 +178,7 @@ class JackShmReadWritePtr
Init(index, server_name);
}

virtual ~JackShmReadWritePtr()
~JackShmReadWritePtr()
{
if (fInfo.index >= 0) {
jack_log("JackShmReadWritePtr::~JackShmReadWritePtr %ld", fInfo.index);
@@ -260,7 +264,7 @@ class JackShmReadWritePtr1
Init(index, server_name);
}

virtual ~JackShmReadWritePtr1()
~JackShmReadWritePtr1()
{
if (fInfo.index >= 0) {
jack_log("JackShmReadWritePtr1::~JackShmReadWritePtr1 %ld", fInfo.index);
@@ -340,7 +344,7 @@ class JackShmReadPtr
Init(index, server_name);
}

virtual ~JackShmReadPtr()
~JackShmReadPtr()
{
if (fInfo.index >= 0) {
jack_log("JackShmPtrRead::~JackShmPtrRead %ld", fInfo.index);


+ 2
- 6
common/JackSocket.h View File

@@ -20,8 +20,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#ifndef __JackSocket__
#define __JackSocket__

#include "JackChannelTransaction.h"

#include <sys/un.h>
#include <sys/types.h>
#include <sys/socket.h>
@@ -42,7 +40,7 @@ namespace Jack
\brief Client socket.
*/

class JackClientSocket : public JackChannelTransaction
class JackClientSocket
{

private:
@@ -54,8 +52,6 @@ class JackClientSocket : public JackChannelTransaction
JackClientSocket(): fSocket( -1)
{}
JackClientSocket(int socket);
virtual ~JackClientSocket()
{}

int Connect(const char* dir, int which);
int Connect(const char* dir, const char* name, int which);
@@ -88,7 +84,7 @@ class JackServerSocket

JackServerSocket(): fSocket( -1)
{}
virtual ~JackServerSocket()
~JackServerSocket()
{}

int Bind(const char* dir, int which);


+ 4
- 2
common/JackThread.h View File

@@ -42,13 +42,15 @@ namespace Jack
class JackRunnableInterface
{
public:
protected:
JackRunnableInterface()
{}
virtual ~JackRunnableInterface()
{}
public:
virtual bool Init() /*! Called once when the thread is started */
{
return true;


+ 1
- 1
linux/alsa/JackAlsaDriver.cpp View File

@@ -2194,7 +2194,7 @@ int JackAlsaDriver::Detach()
if (alsa_driver->midi)
(alsa_driver->midi->detach)(alsa_driver->midi);

return JackDriver::Detach();
return JackAudioDriver::Detach();
}

int JackAlsaDriver::Open(jack_nframes_t nframes,


+ 1
- 1
macosx/JackMachClientChannel.h View File

@@ -46,7 +46,7 @@ class JackMachClientChannel : public detail::JackClientChannelInterface, public
public:

JackMachClientChannel();
virtual ~JackMachClientChannel();
~JackMachClientChannel();

int Open(const char* server_name, const char* name, char* name_res, JackClient* client, jack_options_t options, jack_status_t* status);
void Close();


+ 5
- 1
macosx/Jackdmp.xcodeproj/project.pbxproj View File

@@ -4589,6 +4589,7 @@
08FB7793FE84155DC02AAC07 /* Project object */ = {
isa = PBXProject;
buildConfigurationList = 4B699DD5097D427F00A18468 /* Build configuration list for PBXProject "Jackdmp" */;
compatibilityVersion = "Xcode 2.4";
hasScannedForEncodings = 1;
mainGroup = 08FB7794FE84155DC02AAC07 /* JackServer */;
projectDirPath = "";
@@ -9854,7 +9855,10 @@
4B363EE70DEB091C001F72D9 /* Deployment */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = i386;
ARCHS = (
i386,
ppc,
);
COPY_PHASE_STRIP = YES;
FRAMEWORK_SEARCH_PATHS = "";
GCC_ENABLE_FIX_AND_CONTINUE = NO;


+ 1
- 2
windows/JackWinNamedPipe.h View File

@@ -20,7 +20,6 @@ This program is free software; you can redistribute it and/or modify
#ifndef __JackWinNamedPipe__
#define __JackWinNamedPipe__

#include "JackChannelTransaction.h"
#include <assert.h>
#include <stdio.h>
#include <windows.h>
@@ -28,7 +27,7 @@ This program is free software; you can redistribute it and/or modify
namespace Jack
{

class JackWinNamedPipe : public JackChannelTransaction
class JackWinNamedPipe
{

protected:


Loading…
Cancel
Save