113572SpstToDo: -*- text -*- 213572Spst 313572Spst---------------------------------------------------------------------- 413572SpstMemory allocation locality: 513572Spst 613572SpstCurrently mallocs memory in a very haphazard manner. As such, most of 713572Spstthe program ends up core-resident all the time just to follow all the 813572Spststupid pointers around. . . . 913572Spst 1013572Spst---------------------------------------------------------------------- 1113572SpstInput parser: 1213572Spst 1313572SpstThe reader implemented in readfile.c could use improvement. Some sort 1413572Spstof "data-driven" parser should be used so the big switch statements 1513572Spstwould have only one case for each data type instead of one case for 1613572Spstevery recognized option symbol. Then adding a new tag would involve 1713572Spstonly adding a new element to the data table describing known symbols. 1813572SpstHopefully, this would shrink the code a bit too. -gwr 1913572Spst 2013572Spst---------------------------------------------------------------------- 2113572SpstSLIP Initialization via BOOTP: 2213572Spst 2313572SpstIn the function handle_request(), both in bootpd and bootpgw, 2413572Spstwe might want to add code like the following just before testing 2513572Spstthe client IP address field for zero. (bp->bp_ciaddr == 0) 2613572Spst(David suggests we leave this out for now. -gwr) 2713572Spst 2813572Spst#if 1 /* XXX - Experimental */ 2913572Spst /* 3013572Spst * SLIP initialization support. 3113572Spst * 3213572Spst * If this packet came from a SLIP driver that does 3313572Spst * automatic IP address initialization, then the socket 3413572Spst * will have the IP address and the packet will 3513572Spst * have zeros for both the IP and HW addresses. 3613572Spst * 3713572Spst * Thanks to David P. Maynard <dpm@depend.com> 3813572Spst * for explaining how this works. -gwr 3913572Spst */ 4013572Spst if ((bp->bp_ciaddr.s_addr == 0) && 4113572Spst (bp->bp_htype == 0)) 4213572Spst { 4313572Spst /* Pretend the client knows its address. It will soon. */ 4413572Spst bp->bp_ciaddr = recv_addr.sin_addr; 4513572Spst if (debug) 4613572Spst report(LOG_INFO, "fixed blank request from IP addr %s", 4713572Spst inet_ntoa(recv_addr.sin_addr)); 4813572Spst } 4913572Spst#endif 5013572Spst 5113572Spst---------------------------------------------------------------------- 5213572SpstDHCP Support: 5313572Spst 5413572SpstThere is a set of patches from Jeanette Pauline Middelink 5513572Spst<middelin@calvin.polyware.iaf.nl> to add DHCP support. 5613572Spst 5713572SpstThose patches will be integrated into the BOOTP release stream 5813572Spstvery soon, but if you can't wait, you can get them from: 5913572Spstnimbus.anu.edu.au:/pub/tridge/samba/contributed/DHCP.patch 6013572Spst 6113572Spst---------------------------------------------------------------------- 62