Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
re6stnet
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Joanne Hugé
re6stnet
Commits
4fda2dc7
Commit
4fda2dc7
authored
Jul 03, 2018
by
Julien Muchembled
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix wrong WARNING when own ip is unknown at startup
parent
d7a4d73f
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
10 deletions
+15
-10
re6st/cache.py
re6st/cache.py
+7
-4
re6st/tunnel.py
re6st/tunnel.py
+8
-6
No files found.
re6st/cache.py
View file @
4fda2dc7
...
@@ -203,12 +203,15 @@ class Cache(object):
...
@@ -203,12 +203,15 @@ class Cache(object):
def
my_address
(
self
):
def
my_address
(
self
):
for
x
,
in
self
.
_db
.
execute
(
"SELECT address FROM peer WHERE NOT prefix"
):
for
x
,
in
self
.
_db
.
execute
(
"SELECT address FROM peer WHERE NOT prefix"
):
return
x
return
x
return
''
@
my_address
.
setter
@
my_address
.
setter
def
my_address
(
self
,
*
args
):
def
my_address
(
self
,
value
):
if
value
:
with
self
.
_db
as
db
:
with
self
.
_db
as
db
:
db
.
execute
(
"INSERT OR REPLACE INTO peer VALUES ('', ?)"
,
args
)
db
.
execute
(
"INSERT OR REPLACE INTO peer VALUES ('', ?)"
,
(
value
,))
else
:
del
self
.
my_address
@
my_address
.
deleter
@
my_address
.
deleter
def
my_address
(
self
):
def
my_address
(
self
):
...
...
re6st/tunnel.py
View file @
4fda2dc7
...
@@ -213,7 +213,9 @@ class BaseTunnelManager(object):
...
@@ -213,7 +213,9 @@ class BaseTunnelManager(object):
if
any
(
address_dict
.
itervalues
()):
if
any
(
address_dict
.
itervalues
()):
del
cache
.
my_address
del
cache
.
my_address
else
:
else
:
for
address
in
utils
.
parse_address
(
cache
.
my_address
):
address
=
cache
.
my_address
if
address
:
for
address
in
utils
.
parse_address
(
address
):
try
:
try
:
proto
=
proto_dict
[
address
[
2
]]
proto
=
proto_dict
[
address
[
2
]]
except
KeyError
:
except
KeyError
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment