code: public boolean addToCorruptReplicasMap(Block blk, DatanodeDescriptor dn) {
      Collection<DatanodeDescriptor> nodes = getNodes(blk);
      if (nodes == null) {
        nodes = new TreeSet<DatanodeDescriptor>();
        corruptReplicasMap.put(blk, nodes);
      }
      boolean added = false;
      if (!nodes.contains(dn)) {
        added = nodes.add(dn);
        NameNode.stateChangeLog.info("BLOCK NameSystem.addToCorruptReplicasMap: "+
                                     blk.getBlockName() +
                                     " added as corrupt on " + dn.getName() +
                                     " by " + Server.getRemoteIp());
      } else {
        NameNode.stateChangeLog.info("BLOCK NameSystem.addToCorruptReplicasMap: "+
                                     "duplicate requested for " + 
                                     blk.getBlockName() + " to add as corrupt " +
                                     "on " + dn.getName() +
                                     " by " + Server.getRemoteIp());
      }
      return added;
    }
docs: Mark the block belonging to datanode as corrupt.
  
  @param blk Block to be added to CorruptReplicasMap
  @param dn DatanodeDescriptor which holds the corrupt replica
  @return if the block gets added or not