It depends on the nature of the censoring.
For example, if you start with the same number of worms for each diet, don't lose any worms from the study, and stop monitoring after 10 days, then a diet with more deaths will necessarily have fewer cases censored at 10 days. There's no problem with that.
There would be a problem in this scenario if some worms became lost, and thus censored, during the course of the 10 days in a way that depended on the diets. As a silly example, if one diet gave worms the strength to jump out of their dishes at 5 days and thus become lost to observation, you would have a type of informative censoring.
Dealing with censoring that is potentially due to the treatments is not straightforward. It's important to understand as well as possible the reason for censoring and incorporate that into the analysis. This paper discusses the general issues and suggests some approaches depending on the nature of the censoring (e.g., patients taken off a study drug due to side effects).
You might also consider censoring before the planned end of the observations to be a risk competing with death in a multi-state model, if you have total worm counts over time. This vignette is a good introduction to analysis of multi-state survival models, with examples in R. You will have to use your (or other worm runners') knowledge of the subject matter to decide whether such multi-state models could be reasonable and, if so, which of several forms they could take.