Self-similar solutions of the non-linear diffusion equation and application to near-critical fluids