trans.getAnyTransferData(flavor, dataObj, len); if (!dataObj) continue; 
try { trans.getAnyTransferData(flavor, dataObj, len); } catch (ex) { dragSession.canDrop = false; return false; } 
  canDrop: function(index, orientation)  {    if (orientation != Components.interfaces.nsITreeView.DROP_ON)      return false;    var targetResource = dirTree.builderView.getResourceAtIndex(index);    var targetURI = targetResource.Value;    var srcURI = GetSelectedDirectory();    // The same place case    if (targetURI == srcURI)      return false;    // determine if we dragging from a mailing list on a directory x to the parent (directory x).    // if so, don't allow the drop    if (srcURI.substring(0, targetURI.length) == targetURI)      return false    // check if we can write to the target directory     // e.g. LDAP is readonly currently    var targetDirectory = GetDirectoryFromURI(targetURI);    if (!(targetDirectory.operations & targetDirectory.opWrite))      return false;    var dragSession = dragService.getCurrentSession();    if (!dragSession)      return false;    // If target directory is a mailing list, then only allow copies.    if (targetDirectory.isMailList &&         dragSession.dragAction != Components.interfaces.                                   nsIDragService.DRAGDROP_ACTION_COPY)      return false;    var srcDirectory = GetDirectoryFromURI(srcURI);    // Only allow copy from read-only directories.    if (!(srcDirectory.operations & srcDirectory.opWrite) &&        dragSession.dragAction != Components.interfaces.                                  nsIDragService.DRAGDROP_ACTION_COPY)      return false;    // Go through the cards checking to see if one of them is a mailing list    // (if we are attempting a copy) - we can't copy mailing lists as    // that would give us duplicate names which isn't allowed at the    // moment.    var draggingMailList = false;    var abView = GetAbView();    var trans = Components.classes["@mozilla.org/widget/transferable;1"].                createInstance(Components.interfaces.nsITransferable);    trans.addDataFlavor("moz/abcard");    for (var i = 0; i < dragSession.numDropItems && !draggingMailList; i++)    {      dragSession.getData(trans, i);      var dataObj = new Object();      var flavor = new Object();      var len = new Object();      trans.getAnyTransferData(flavor, dataObj, len);      if (!dataObj)        continue;      dataObj = dataObj.value.QueryInterface(Components.interfaces.nsISupportsString);      var transData = dataObj.data.split("\n");      var rows = transData[0].split(",");      for (var j = 0; j < rows.length; j++)      {        if (abView.getCardFromRow(rows[j]).isMailList)        {          draggingMailList = true;          break;        }      }    }    // The rest of the cases - allow cards for copy or move, but only allow    // move of mailing lists if we're not going into another mailing list.    if (draggingMailList &&        (targetDirectory.isMailList ||         dragSession.dragAction == Components.interfaces.                                   nsIDragService.DRAGDROP_ACTION_COPY))    {      return false;    }    dragSession.canDrop = true;    return true;  },
5872	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/5872/94b8a218de513b4d838d354dbe98ab9bea2221d7/abDragDrop.js/buggy/mailnews/addrbook/resources/content/abDragDrop.js