-
Notifications
You must be signed in to change notification settings - Fork 241
Basic IPv6 support for Jamulus #1455
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
649537e
585ea3c
490d36f
f19713d
45a02ff
45a3d93
bcfd5d0
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -31,7 +31,8 @@ CClient::CClient ( const quint16 iPortNumber, | |
| const QString& strMIDISetup, | ||
| const bool bNoAutoJackConnect, | ||
| const QString& strNClientName, | ||
| const bool bNMuteMeInPersonalMix ) : | ||
| const bool bNMuteMeInPersonalMix, | ||
| int ipmode ) : | ||
| ChannelInfo ( ), | ||
| strClientName ( strNClientName ), | ||
| Channel ( false ), /* we need a client channel -> "false" */ | ||
|
|
@@ -62,6 +63,7 @@ CClient::CClient ( const quint16 iPortNumber, | |
| bEnableOPUS64 ( false ), | ||
| bJitterBufferOK ( true ), | ||
| bNuteMeInPersonalMix ( bNMuteMeInPersonalMix ), | ||
| iipmode ( ipmode ), | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As above - spaces not tabs, please. |
||
| iServerSockBufNumFrames ( DEF_NET_BUF_SIZE_NUM_BL ), | ||
| pSignalHandler ( CSignalHandler::getSingletonP() ) | ||
| { | ||
|
|
@@ -389,7 +391,8 @@ bool CClient::SetServerAddr ( QString strNAddr ) | |
| { | ||
| CHostAddress HostAddress; | ||
| if ( NetworkUtil().ParseNetworkAddress ( strNAddr, | ||
| HostAddress ) ) | ||
| HostAddress, | ||
| iipmode ) ) | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As above. |
||
| { | ||
| // apply address to the channel | ||
| Channel.SetAddress ( HostAddress ); | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -113,7 +113,8 @@ class CClient : public QObject | |
| const QString& strMIDISetup, | ||
| const bool bNoAutoJackConnect, | ||
| const QString& strNClientName, | ||
| const bool bNMuteMeInPersonalMix ); | ||
| const bool bNMuteMeInPersonalMix, | ||
| int ipmode=0 ); | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As above. |
||
|
|
||
| virtual ~CClient(); | ||
|
|
||
|
|
@@ -355,6 +356,7 @@ class CClient : public QObject | |
|
|
||
| bool bJitterBufferOK; | ||
| bool bNuteMeInPersonalMix; | ||
| int iipmode; | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As above. |
||
| QMutex MutexDriverReinit; | ||
|
|
||
| // server settings | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -88,6 +88,7 @@ int main ( int argc, char** argv ) | |
| QString strServerListFilter = ""; | ||
| QString strWelcomeMessage = ""; | ||
| QString strClientName = ""; | ||
| int ipmode = 0; | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As above. |
||
|
|
||
| #if !defined(HEADLESS) && defined(_WIN32) | ||
| if (AttachConsole(ATTACH_PARENT_PROCESS)) { | ||
|
|
@@ -140,6 +141,41 @@ int main ( int argc, char** argv ) | |
| continue; | ||
| } | ||
|
|
||
| // Use ipv4 protocol | ||
| if ( GetFlagArgument ( argv, | ||
| i, | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As above. |
||
| "-4", | ||
| "--ipv4" )) | ||
| { | ||
| switch (ipmode) | ||
| { | ||
| case 0: ipmode = 1; break; | ||
| case 1: break; | ||
| case 2: ipmode = 3; break; | ||
| case 3: break; | ||
| default: break; | ||
| } | ||
| CommandLineOptions << "--ipv4"; | ||
| continue; | ||
| } | ||
|
|
||
| // Use ipv6 protocol | ||
| if ( GetFlagArgument ( argv, | ||
| i, | ||
| "-6", | ||
| "--ipv6" )) | ||
| { | ||
| switch (ipmode) | ||
| { | ||
| case 0: ipmode = 2; break; | ||
| case 1: ipmode = 0; break; | ||
| case 2: break; | ||
| case 3: break; | ||
| default: break; | ||
| } | ||
| CommandLineOptions << "--ipv6"; | ||
| continue; | ||
| } | ||
|
|
||
| // Use 64 samples frame size mode -------------------------------------- | ||
| if ( GetFlagArgument ( argv, | ||
|
|
@@ -697,7 +733,8 @@ int main ( int argc, char** argv ) | |
| strMIDISetup, | ||
| bNoAutoJackConnect, | ||
| strClientName, | ||
| bMuteMeInPersonalMix ); | ||
| bMuteMeInPersonalMix, | ||
| ipmode ); | ||
|
|
||
| // load settings from init-file (command line options override) | ||
| CClientSettings Settings ( &Client, strIniFileName ); | ||
|
|
@@ -846,6 +883,8 @@ QString UsageArguments ( char **argv ) | |
| " -p, --port set your local port number\n" | ||
| " -t, --notranslation disable translation (use English language)\n" | ||
| " -v, --version output version information and exit\n" | ||
| " -4, --ipv4 use IPv4 Protocol\n" | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As above. |
||
| " -6 --ipv6 use IPv6 Protocol (order of -4 and -6 will be followed\n" | ||
| "\nServer only:\n" | ||
| " -d, --discononquit disconnect all clients on quit\n" | ||
| " -e, --centralserver address of the server list on which to register\n" | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use spaces, be consistent with the existing source.