My impression has been that publications are a nice plus to be a little more competitive, but certainly not -required- for getting a fellowship. Frankly many pathology fellowships are not terribly competitive, some subspecialties/highly-regarded programs excepted, so long as you go searching for the positions early enough. But sure, if you're sizing up a competitive fellowship and will only be happy at one or two institutions, then you should probably do some relevant and recent research. This will almost certainly change with the implementation of a fellowship match or narrowed standard timeframe for applications.
As for med-school publications.. eh, I don't think they mean that much if you haven't done anything during residency. But almost any path publication during residency is useful, simply to show that you're willing and capable of putting it all together despite having a job and studying to do; being specialty specific is just another bonus -- but again, depends on the level of competition for your subspecialty/program of interest. It's really not a matter of "counting", inasmuch as fellowship applications are not looked at by a computer making a decision how to give you points, but by people making partially objective but largely subjective decisions.