Added maxdup option