Skip to content
Snippets Groups Projects
Commit 7b0b60bd authored by Bob Mottram's avatar Bob Mottram
Browse files

Fixed tracker port

parent 1d7c46db
No related branches found
No related tags found
No related merge requests found
......@@ -28,7 +28,7 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
TRANSMISSION_PORT=
TRACKER_PORT=51413
BOOTSTRAP_FILE=/opt/zeronet/bootstrap
if [ ! -d /opt/zeronet ]; then
......@@ -47,20 +47,13 @@ fi
state=0
address=""
port=0
peer=""
while IFS='' read -r line || [[ -n "$line" ]]; do
if [ ${state} -eq "3" ]; then
if [[ $line == *"port ="* ]]; then
port=$(echo $line | awk -F '[' '{print $2}' | awk -F ']' '{print $1}')
echo "udp $address $port" >> $BOOTSTRAP_FILE.new
state=0
fi
fi
if [ ${state} -eq "2" ]; then
if [[ $line == *"address ="* ]]; then
address=$(echo $line | awk -F '[' '{print $2}' | awk -F ']' '{print $1}')
state=3
echo "udp $address $TRACKER_PORT" >> $BOOTSTRAP_FILE.new
state=0
fi
fi
if [ ${state} -eq "1" ]; then
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment