Compare how you called add_length and the other member functions. With the others, you correctly call them with their respective objects. The same is not rue on line 49.
1 2 3
l_tot = add_length(12);
//Should be
l_tot.add_length(12);
You can either change your add_length function to modify the member variables to reflect the change or make it a friend, non-member function that takes a parameter of type length.