Opened 7 years ago

Closed 7 years ago

#3030 closed defect (fixed)

Remove use of boost ISO string functions in DHCP-DDNS

Reported by: tmark Owned by: tmark
Priority: high Milestone: Sprint-DHCP-20130717
Component: ~dhcp-ddns(obsolete) Version:
Keywords: Cc:
CVSS Scoring: Parent Tickets:
Sensitive: no Defect Severity: N/A
Sub-Project: DHCP Feature Depending on Ticket:
Estimated Difficulty: 0 Add Hours to Ticket: 0
Total Hours: 0 Internal?: no

Description

trac3007 introduced the DHCP-DDNS message class NameChangeRequest?. This class was using boost::posix_time::ptime and to_iso_string and from_iso_string. This resulted in link errors on some machines in the build farm:
libtool: link: g++ -Wall -Wextra -Wwrite-strings -Woverloaded-virtual -Wno-sign-compare -Werror -fPIC -m32 -o .libs/b10-dhcp-ddns main.o d2_log.o d2_process.o d_controller.o d2_controller.o d_cfg_mgr.o d2_config.o d2_cfg_mgr.o d2_update_message.o d2_zone.o ncr_msg.o d2_messages.o -Wl,-bind_at_load ../../../src/lib/log/.libs/libb10-log.dylib -L/Local/Users/jreed/opt/pkg/lib ../../../src/lib/exceptions/.libs/libb10-exceptions.dylib ../../../src/lib/cc/.libs/libb10-cc.dylib ../../../src/lib/asiolink/.libs/libb10-asiolink.dylib ../../../src/lib/config/.libs/libb10-cfgclient.dylib ../../../src/lib/dhcpsrv/.libs/libb10-dhcpsrv.dylib /b/work/BIND10-lettuce/20130703051903-MacOSX10.6-x86_64-GCC/build/src/lib/dhcp/.libs/libb10-dhcp++.dylib /b/work/BIND10-lettuce/20130703051903-MacOSX10.6-x86_64-GCC/build/src/lib/asiolink/.libs/libb10-asiolink.dylib /b/work/BIND10-lettuce/20130703051903-MacOSX10.6-x86_64-GCC/build/src/lib/dns/.libs/libb10-dns++.dylib /b/work/BIND10-lettuce/20130703051903-MacOSX10.6-x86_64-GCC/build/src/lib/cc/.libs/libb10-cc.dylib /b/work/BIND10-lettuce/20130703051903-MacOSX10.6-x86_64-GCC/build/src/lib/log/.libs/libb10-log.dylib /b/work/BIND10-lettuce/20130703051903-MacOSX10.6-x86_64-GCC/build/src/lib/util/threads/.libs/libb10-threads.dylib /Local/Users?/jreed/opt/pkg/lib/liblog4cplus.dylib ../../../src/lib/dns/.libs/libb10-dns++.dylib /b/work/BIND10-lettuce/20130703051903-MacOSX10.6-x86_64-GCC/build/src/lib/cryptolink/.libs/libb10-cryptolink.dylib -lbotan -lpthread /b/work/BIND10-lettuce/20130703051903-MacOSX10.6-x86_64-GCC/build/src/lib/util/.libs/libb10-util.dylib ../../../src/lib/util/.libs/libb10-util.dylib /b/work/BIND10-lettuce/20130703051903-MacOSX10.6-x86_64-GCC/build/src/lib/exceptions/.libs/libb10-exceptions.dylib -pthread
Undefined symbols:

"boost::gregorian::greg_month::as_short_string() const", referenced from:

boost::date_time::month_formatter<boost::gregorian::greg_month, boost::date_time::iso_format<char>, char>::format_month(boost::gregorian::greg_month const&, std::basic_ostream<char, std::char_traits<char> >&)in ncr_msg.o

"boost::gregorian::greg_month::as_long_string() const", referenced from:

boost::date_time::

Subtickets

Change History (5)

comment:1 Changed 7 years ago by tmark

  • Owner set to tmark
  • Status changed from new to assigned

comment:2 Changed 7 years ago by tmark

I changed NameChangeRequest::lease_expires_on_ to be a unit64_t and use isc:util::time_utilities functions, timeToText64() and timeFromText64() to marshal the value to and from the wire.

Also had to replace test time values to not before the EPOCH. These are not supported by time_utilities.

Use of boost::posix_time::from_iso_string() doesn't link correctly on some systems.

comment:3 Changed 7 years ago by tmark

  • Owner changed from tmark to UnAssigned
  • Status changed from assigned to reviewing

comment:4 Changed 7 years ago by marcin

  • Owner changed from UnAssigned to tmark

If found a couple of those:

#if 0
...
#else
...

I understand they are leftover from debugging the code. Please remove them and only leave the code between #else and #endif. When you do, you can merge it in. I don't need to see the code again.

comment:5 Changed 7 years ago by tmark

  • Resolution set to fixed
  • Status changed from reviewing to closed

Conditional compile statements cleaned up. Changes merged into master.

Note: See TracTickets for help on using tickets.