#15 nsd/tclcache.c:756: error: Null Dereference pointer `cPtr` last assigned on line 703 could be null and is dereferenced at line 756, column 28. nsd/tclcache.c:699:1: start of procedure CacheAppendObjCmd() 697. } 698. 699. static int ^ 700. CacheAppendObjCmd(ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *const* objv, bool append) 701. { nsd/tclcache.c:702:5: 700. CacheAppendObjCmd(ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *const* objv, bool append) 701. { 702. NsInterp *itPtr = clientData; ^ 703. TclCache *cPtr = NULL; 704. char *key = NULL; nsd/tclcache.c:703:5: 701. { 702. NsInterp *itPtr = clientData; 703. TclCache *cPtr = NULL; ^ 704. char *key = NULL; 705. int result = TCL_OK, nelements = 0; nsd/tclcache.c:704:5: 702. NsInterp *itPtr = clientData; 703. TclCache *cPtr = NULL; 704. char *key = NULL; ^ 705. int result = TCL_OK, nelements = 0; 706. Ns_Time *timeoutPtr = NULL, *expPtr = NULL; nsd/tclcache.c:705:5: 703. TclCache *cPtr = NULL; 704. char *key = NULL; 705. int result = TCL_OK, nelements = 0; ^ 706. Ns_Time *timeoutPtr = NULL, *expPtr = NULL; 707. nsd/tclcache.c:706:5: 704. char *key = NULL; 705. int result = TCL_OK, nelements = 0; 706. Ns_Time *timeoutPtr = NULL, *expPtr = NULL; ^ 707. 708. Ns_ObjvSpec opts[] = { nsd/tclcache.c:708:5: 706. Ns_Time *timeoutPtr = NULL, *expPtr = NULL; 707. 708. Ns_ObjvSpec opts[] = { ^ 709. {"-timeout", Ns_ObjvTime, &timeoutPtr, NULL}, 710. {"-expires", Ns_ObjvTime, &expPtr, NULL}, nsd/tclcache.c:714:5: 712. {NULL, NULL, NULL, NULL} 713. }; 714. Ns_ObjvSpec args[] = { ^ 715. {"cache", ObjvCache, &cPtr, clientData}, 716. {"key", Ns_ObjvString, &key, NULL}, nsd/tclcache.c:720:5: 718. {NULL, NULL, NULL, NULL} 719. }; 720. args[0].arg = clientData; /* pass non-constant clientData for "cache" */ ^ 721. 722. if (Ns_ParseObjv(opts, args, interp, 1, objc, objv) != NS_OK) { nsd/tclcache.c:722:9: Taking false branch 720. args[0].arg = clientData; /* pass non-constant clientData for "cache" */ 721. 722. if (Ns_ParseObjv(opts, args, interp, 1, objc, objv) != NS_OK) { ^ 723. result = TCL_ERROR; 724. nsd/tclcache.c:728:9: 726. int isNew; 727. Ns_Entry *entry; 728. Ns_CacheTransactionStack *transactionStackPtr = &itPtr->cacheTransactionStack; ^ 729. 730. assert(cPtr != NULL); nsd/tclcache.c:730:9: 728. Ns_CacheTransactionStack *transactionStackPtr = &itPtr->cacheTransactionStack; 729. 730. assert(cPtr != NULL); ^ 731. assert(key != NULL); 732. nsd/tclcache.c:731:9: 729. 730. assert(cPtr != NULL); 731. assert(key != NULL); ^ 732. 733. entry = CreateEntry(itPtr, cPtr, key, &isNew, timeoutPtr, transactionStackPtr); nsd/tclcache.c:733:9: Skipping CreateEntry(): empty list of specs 731. assert(key != NULL); 732. 733. entry = CreateEntry(itPtr, cPtr, key, &isNew, timeoutPtr, transactionStackPtr); ^ 734. if (entry == NULL) { 735. result = TCL_ERROR; nsd/tclcache.c:734:13: Taking false branch 732. 733. entry = CreateEntry(itPtr, cPtr, key, &isNew, timeoutPtr, transactionStackPtr); 734. if (entry == NULL) { ^ 735. result = TCL_ERROR; 736. } else { nsd/tclcache.c:737:13: Skipping Tcl_NewObj(): method has no implementation 735. result = TCL_ERROR; 736. } else { 737. Tcl_Obj *valObj = Tcl_NewObj(); ^ 738. int i; 739. nsd/tclcache.c:740:17: Taking false branch 738. int i; 739. 740. if (isNew == 0) { ^ 741. Tcl_SetStringObj(valObj, Ns_CacheGetValueT(entry, transactionStackPtr), 742. (int)Ns_CacheGetSize(entry)); nsd/tclcache.c:744:18: 742. (int)Ns_CacheGetSize(entry)); 743. } 744. for (i = objc - nelements; i < objc; i++) { ^ 745. if (append) { 746. Tcl_AppendObjToObj(valObj, objv[i]); nsd/tclcache.c:744:40: Loop condition is false. Leaving loop 742. (int)Ns_CacheGetSize(entry)); 743. } 744. for (i = objc - nelements; i < objc; i++) { ^ 745. if (append) { 746. Tcl_AppendObjToObj(valObj, objv[i]); nsd/tclcache.c:752:17: Taking true branch 750. } 751. } 752. if (result == TCL_OK) { ^ 753. SetEntry(itPtr, cPtr, entry, valObj, expPtr, 0); 754. Tcl_SetObjResult(interp, valObj); nsd/tclcache.c:753:17: Skipping SetEntry(): empty list of specs 751. } 752. if (result == TCL_OK) { 753. SetEntry(itPtr, cPtr, entry, valObj, expPtr, 0); ^ 754. Tcl_SetObjResult(interp, valObj); 755. } nsd/tclcache.c:754:17: Skipping Tcl_SetObjResult(): method has no implementation 752. if (result == TCL_OK) { 753. SetEntry(itPtr, cPtr, entry, valObj, expPtr, 0); 754. Tcl_SetObjResult(interp, valObj); ^ 755. } 756. Ns_CacheUnlock(cPtr->cache); nsd/tclcache.c:756:13: 754. Tcl_SetObjResult(interp, valObj); 755. } 756. Ns_CacheUnlock(cPtr->cache); ^ 757. } 758. }