Well you could at least have logged the exception!

On Mon, Apr 03, 2006 at 08:13:44PM +0200, Florent Daigni?re (NextGen$) wrote:
> * Matthew Toseland <toad at amphibian.dyndns.org> [2006-04-03 17:51:53]:
> 
> > What on earth are you doing here?
> > 
> 
> if the value can't be parsed it's randomized : it's needed otherwise it
> was throwing a weird exception. maybe I should have fixed the callback
> insteed ;)
> 
> the node's constructor isn't finished at this stage and portNumber is
> *not* defined
> 
> 
> nodeConfig.register("listenPort", -1 /* means random */, 1,
>               true, "FNP port number (UDP)", "UDP port for node-to-node
>               communications (Freenet Node Protocol)",
> new IntCallback() {
> public        int     get()
> {
>  return       portNumber;
>                                                                               
>                                                                               
>   }
> 
> 
> > On Sun, Apr 02, 2006 at 12:58:52PM +0000, nextgens at freenetproject.org 
> > wrote:
> > > Author: nextgens
> > > Date: 2006-04-02 12:58:15 +0000 (Sun, 02 Apr 2006)
> > > New Revision: 8431
> > > 
> > > Modified:
> > >    trunk/freenet/src/freenet/node/Node.java
> > >    trunk/freenet/src/freenet/node/Version.java
> > > Log:
> > > 612:
> > > 
> > > Needed to save me a headache with the installer
> > > 
> > > Modified: trunk/freenet/src/freenet/node/Node.java
> > > ===================================================================
> > > --- trunk/freenet/src/freenet/node/Node.java      2006-04-02 12:43:30 UTC 
> > > (rev 8430)
> > > +++ trunk/freenet/src/freenet/node/Node.java      2006-04-02 12:58:15 UTC 
> > > (rev 8431)
> > > @@ -578,7 +578,12 @@
> > >                                   }
> > >           });
> > >           
> > > -         int port = nodeConfig.getInt("listenPort");
> > > +         int port=-1;
> > > +         try{
> > > +                 port=nodeConfig.getInt("listenPort");
> > > +         }catch (Exception e){
> > > +                 port=-1;
> > > +         }
> > >           
> > >           UdpSocketManager u = null;
> > >           
> > > @@ -896,11 +901,10 @@
> > >                                   }
> > >          });
> > >          myName = nodeConfig.getString("name");
> > > - 
> > > +     
> > > +        nodeConfig.finishedInitialization();
> > >          writeNodeFile();
> > >          
> > > -        nodeConfig.finishedInitialization();
> > > -        
> > >          // FIXME make all the below arbitrary constants configurable!
> > >          
> > >           archiveManager = new ArchiveManager(MAX_ARCHIVE_HANDLERS, 
> > > MAX_CACHED_ARCHIVE_DATA, MAX_ARCHIVE_SIZE, MAX_ARCHIVED_FILE_SIZE, 
> > > MAX_CACHED_ELEMENTS, random, tempFilenameGenerator);
> > > 
> > > Modified: trunk/freenet/src/freenet/node/Version.java
> > > ===================================================================
> > > --- trunk/freenet/src/freenet/node/Version.java   2006-04-02 12:43:30 UTC 
> > > (rev 8430)
> > > +++ trunk/freenet/src/freenet/node/Version.java   2006-04-02 12:58:15 UTC 
> > > (rev 8431)
> > > @@ -20,7 +20,7 @@
> > >   public static final String protocolVersion = "1.0";
> > >  
> > >   /** The build number of the current revision */
> > > - private static final int buildNumber = 611;
> > > + private static final int buildNumber = 612;
> > >  
> > >   /** Oldest build of Fred we will talk to */
> > >   private static final int lastGoodBuild = 591;
> > > 
> > > _______________________________________________
> > > cvs mailing list
> > > cvs at freenetproject.org
> > > http://emu.freenetproject.org/cgi-bin/mailman/listinfo/cvs
> > > 
> > 
> > -- 
> > Matthew J Toseland - toad at amphibian.dyndns.org
> > Freenet Project Official Codemonkey - http://freenetproject.org/
> > ICTHUS - Nothing is impossible. Our Boss says so.
> 
> 
> 
> > _______________________________________________
> > Devl mailing list
> > Devl at freenetproject.org
> > http://emu.freenetproject.org/cgi-bin/mailman/listinfo/devl



> _______________________________________________
> Devl mailing list
> Devl at freenetproject.org
> http://emu.freenetproject.org/cgi-bin/mailman/listinfo/devl

-- 
Matthew J Toseland - toad at amphibian.dyndns.org
Freenet Project Official Codemonkey - http://freenetproject.org/
ICTHUS - Nothing is impossible. Our Boss says so.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: 
<https://emu.freenetproject.org/pipermail/devl/attachments/20060403/866236d3/attachment.pgp>

Reply via email to