I've done this as well, but charging does not stop when the voltage reaches 4.2 volts, and if you disconnect the supply at this point the cell will only be partly charged.
To get a full charge, leave the cell charging at 4.2V until the current reaches about 10% of the initial charge rate. It's dangerous to leave lithium cells 'trickle charging', so you need to calculate the time at which this will occur and set an alarm so you don't leave it too long.
Unless it's an infrequent operation, you are much better off with a proper charger.