Differential equation: mixing salt into water problem where there is also leakage. Is my differential equation correct, and how to solve? 
Initially, a tank contains $50$ litres of water and the tank water contains no
salt. Salt is added to the water at time $t=0,$ at a constant rate
of $5$ grams per minute. The salt does not change the volume of the
water in the tank. The water in the tank is stirred constantly, so
that the concentration of salt throughout the tank is uniform. Furthermore,
the saltwater solution leaks out the tank a constant rate of $100$ml per minute. What is
the concentration of salt in the tank after $4$ hours?

My attempt:
Let $t$ be time in minutes, let $V(t)$ be the volume of water at time $t$, and let $m(t)$ be the mass of salt dissolved in the water in the tank at time $t$.
Then, changing units of volume from litres into metres cubed, $V(t) = (0.05 - 0.0001t) m^3.$
Now, in order to find the rate of mass of salt leaving the tank with respect to time, we first should find the concentration of salt in the tank water.
Concentration of salt in tank water = $\left(\frac{m(t)}{V(t)}\right)\ = \left(\frac{m(t)}{0.05 - 0.0001t}\right)\ g/m^3.\ $ Hence we need only need to find $\ m(240)\ $ and then the answer to the question is just $\left(\frac{m(240)}{0.05 - 0.0001\times 240}\right)\ g/m^3. $
Now I believe that the rate at which the mass of the salt leaks out the tank with respect to time is (concentration of salt in tank water in $g/m^3$) $\times$ (the rate at which water leaks out the tank in $m^3$/second), although I am not certain of this.
On the basis that this is all correct so far, the mass of salt in the water in the tank should satisfy the differential equation:
$$\frac{dm}{dt} = 5 - 0.0001 \times \left(\frac{m(t)}{0.05 - 0.0001t}\right),$$
or to tidy up the final term,
$$\frac{dm}{dt} = 5 - \frac{m(t)}{500 - t}.$$
I am not sure how to solve such an equation. Wolfram Alpha says that the general solution is:
$$m(t) = c(t-500) + 5(t-500)\log(t-500).$$
However, this doesn't allow for the initial condition $m(0) = 0$ to be satisfied, so something has gone wrong here. Perhaps $\log(t-500)$ should be $\log\lvert t-500 \rvert$ ? Or Is it the differential equation itself wrong? I suspect so, in which case, can someone give me a hint as to how to figure out what the differential equation should be ?
I am looking for pointers in the right direction, rather than a complete solution to the problem.
 A: At first, in order to simplify things a bit, we get rid of grams, minutes and litres. So the mass of salt in the saltwater $m(t)$ is in grams, the volume of saltwater in litres and the time in minutes.
Clearly, the volume of the salt water is
$$
V(t)=50-\frac{t}{10}
$$
Equation for $m(t)$:
The amount of salt in the saltwater increases in time $\Delta t$ by $5 \Delta t$ and decreases by
$$
\frac{.1}{V(t)} m(t)\Delta t=\frac{1}{500-t} m(t)\Delta t,
$$ thus
$$
m(t+\Delta t)-m(t)=5\Delta t-\frac{m(t)\,\Delta t}{500-t},
$$
and hence the sought for ODE is
$$
m'=5-\frac{m}{500-t}
$$
with initial value $m(0)=0$. Solving the IVP we obtain
$$
\frac{m'}{500-t}+\frac{m}{(500-t)^2}=\frac{5}{500-t}
$$
or
$$
\left(\frac{m}{500-t}\right)'=\frac{5}{500-t}
$$
and integrating in the interval $[0,t]$ we obtain
$$
\frac{m(t)}{500-t}=5\log\left(\frac{500}{500-t}\right),
$$
and hence
$$
m(t)=5(500-t)\log\left(\frac{500}{500-t}\right),
$$
and consequently
the concentration of salt in the saltwater will be
$$
c(t)=\frac{5(500-t)\log\left(\frac{500}{500-t}\right)}{50-\frac{t}{10}}=50\log\left(\frac{500}{500-t}\right) \quad\quad\text{[grams/litre]}.
$$
