Author

Topic: Code Editing Questions (Read 1950 times)

member
Activity: 84
Merit: 10
April 25, 2013, 02:49:52 PM
#5
sweet thanks, can the same code be used to compile for unix/pc/windows

I have a windows PC, but I think this smallchange code was originally compiled for unix, didn't know if there was something I need to different if I plan on compiling it for a windows client.

Like the code doesn't scare me more than compiling it later does.
kjj
legendary
Activity: 1302
Merit: 1026
April 25, 2013, 12:10:04 PM
#4
It doesn't matter a whole lot.  You will want to avoid ports that people might be using for other things.  Most things based on the bitcoin source use two sequential ports, so you may want to go up by at least 2, and change both.
member
Activity: 84
Merit: 10
April 25, 2013, 11:55:42 AM
#3
super thanks, does it matter what I change the port number too, could i just add 1 to it.
kjj
legendary
Activity: 1302
Merit: 1026
April 25, 2013, 11:27:31 AM
#2
The server mentioned is the RPC server that lets you interact with the daemon.

9031 is just the default port.  You can change it, and probably should.  The rpcport option in the config file or on the command line will override your default port either way.

Either 40 or 41 will give an initial character of H.
member
Activity: 84
Merit: 10
April 25, 2013, 07:09:18 AM
#1
I'm editing the SmallChange source code which is a liteocoin fork, I'm following the exact changes made to the litecoin source as shown here:

https://github.com/bfroemel/smallchange/commit/947a0fafd8d033f6f0960c4ff0748f76a3d58326



I ran into this piece of code and it raised a few questions...

  // Try a dual IPv6/IPv4 socket, falling back to separate IPv4 and IPv6 sockets
     const bool loopback = !mapArgs.count("-rpcallowip");
     asio::ip::address bindAddress = loopback ? asio::ip::address_v6::loopback() : asio::ip::address_v6::any();
-    ip::tcp::endpoint endpoint(bindAddress, GetArg("-rpcport", 9332));
+    ip::tcp::endpoint endpoint(bindAddress, GetArg("-rpcport", 9031));
 
     boost::signals2::signal StopRequests;
 
@@ -3165,7 +3165,7 @@ Object CallRPC(const string& strMethod, const Array& params)
     asio::ssl::stream sslStream(io_service, context);
     SSLIOStreamDevice d(sslStream, fUseSSL);
     iostreams::stream< SSLIOStreamDevice > stream(d);
-    if (!d.connect(GetArg("-rpcconnect", "127.0.0.1"), GetArg("-rpcport", "9332")))
+    if (!d.connect(GetArg("-rpcconnect", "127.0.0.1"), GetArg("-rpcport", "9031")))
         throw runtime_error("couldn't connect to server");


- Do I have to create a server?, I thought these currencies were decentralized
- If so do I need a static IP, or can I change "9031" to anything?




Second Question:

I want the currency address codes to start with the letter H, here is the code to change it but I can't find a table showing which numbers correspond with which letter:

-        PUBKEY_ADDRESS = 48, // Litecoin addresses start with L
+        PUBKEY_ADDRESS = 62, // addresses start with S
Jump to: