[DONE] Tailbite doesn't close

TailBite specific forum

Moderators: gnozal, ABBKlaus, lexvictory

User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

[DONE] Tailbite doesn't close

Post by ts-soft »

After creation of a resident, tailbite doesn't close correct!
TailBite 1.3 PR 1.872, resident is created

greetings and thanks for the new version
Thomas
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
ABBKlaus
Addict
Addict
Posts: 1143
Joined: Sat Apr 10, 2004 1:20 pm
Location: Germany

Post by ABBKlaus »

fixed
User avatar
Progi1984
Addict
Addict
Posts: 806
Joined: Fri Feb 25, 2005 1:01 am
Location: France > Rennes
Contact:

Post by Progi1984 »

How can I create residents with new version ? Because I updated from 1.3 PR 1.870 to 1.3 PR 1.874 and now, with same code, that doesn't create residents :

Code: Select all

Import "C:\Program Files\PureBasic\Compilers\ObjectManager.lib"
  Object_GetOrAllocateID  (Objects, Object.l) As "_PB_Object_GetOrAllocateID@8"
  Object_GetObject        (Objects, Object.l) As "_PB_Object_GetObject@8"
  Object_IsObject         (Objects, Object.l) As "_PB_Object_IsObject@8"
  Object_EnumerateAll     (Objects, ObjectEnumerateAllCallback, *VoidData) As "_PB_Object_EnumerateAll@12"
  Object_EnumerateStart   (Objects) As "_PB_Object_EnumerateStart@4"
  Object_EnumerateNext    (Objects, *object.Long) As "_PB_Object_EnumerateNext@8"
  Object_EnumerateAbort   (Objects) As "_PB_Object_EnumerateAbort@4"
  Object_FreeID           (Objects, Object.l) As "_PB_Object_FreeID@8"
  Object_Init             (StructureSize.l, IncrementStep.l, ObjectFreeFunction) As "_PB_Object_Init@12"
  Object_GetThreadMemory  (MemoryID.l) As "_PB_Object_GetThreadMemory@4"
  Object_InitThreadMemory (Size.l, InitFunction, EndFunction) As "_PB_Object_InitThreadMemory@12"
EndImport

;{ Structures
  Structure S_RLog
    ID.l
    Default_Level.l
    Default_Category.s
    Default_Formatter.s
    OutputFile.s
    OutputFile_Append.l
    Filter_Activate_Level.l
    Filter_Operator_Level.l
    Filter_Content_Level.l
    Filter_Activate_Date.l
    Filter_Operator_Date.l
    Filter_Content_Date.l
    Filter_Activate_Category.l
    Filter_Operator_Category .l
    Filter_Content_Category.s
  EndStructure
  Structure S_RLog_Log
    ID_Log.l
    Level.l
    Date.l
    Content.s
    Category.s
  EndStructure
;}
;{ Enumerations
  Enumeration 
    #RLog_Level_Debug
    #RLog_Level_Info
    #RLog_Level_Notice
    #RLog_Level_Warn
    #RLog_Level_Error
    #RLog_Level_Critical
    #RLog_Level_Alert
    #RLog_Level_Emergency
  EndEnumeration
  Enumeration 1
    #RLog_Filter_Level
    #RLog_Filter_Date
    #RLog_Filter_Category
  EndEnumeration
  Enumeration 1
    #RLog_Operator_Inferior
    #RLog_Operator_InferiorOrEqual
    #RLog_Operator_Superior
    #RLog_Operator_SuperiorOrEqual
    #RLog_Operator_Equal
    #RLog_Operator_NotEqual
  EndEnumeration
;}
;{ Macros
  Macro RLOG_ID(object)
    Object_GetObject(RLogObjects, object)
  EndMacro
  Macro RLOG_ISID(object)
    Object_IsObject(RLogObjects, object) 
  EndMacro
  Macro RLOG_NEW(object)
    Object_GetOrAllocateID(RLogObjects, object)
  EndMacro
  Macro RLOG_FREEID(object)
    If object <> #PB_Any And RLog_Is(object) = #True
      Object_FreeID(RLogObjects, object)
    EndIf
  EndMacro
  Macro RLOG_INITIALIZE(hCloseFunction)
    Object_Init(SizeOf(S_RLog), 1, hCloseFunction)
  EndMacro
;}

Global NewList LL_RLog_Logs.S_RLog_Log()
ABBKlaus
Addict
Addict
Posts: 1143
Joined: Sat Apr 10, 2004 1:20 pm
Location: Germany

Post by ABBKlaus »

Its simply not working ! Not in V1.3 PR 870 / V1.3 PR 874.
You can test it yourselft : http://www.tailbite.com/downloads/TailB ... R1.870.zip

You could remove the import section / the macro´s / and the global newlist and all works fine.

Regards Klaus
User avatar
Progi1984
Addict
Addict
Posts: 806
Joined: Fri Feb 25, 2005 1:01 am
Location: France > Rennes
Contact:

Post by Progi1984 »

So linked list, macro, imports are stored in userlib and not in resident ?
ABBKlaus
Addict
Addict
Posts: 1143
Joined: Sat Apr 10, 2004 1:20 pm
Location: Germany

Post by ABBKlaus »

Correct.
User avatar
Progi1984
Addict
Addict
Posts: 806
Joined: Fri Feb 25, 2005 1:01 am
Location: France > Rennes
Contact:

Post by Progi1984 »

Woah ! I believe that residents can contain structures, macros, constants, prototypes, linked lists and imports....

So what can contain a resident ?
ABBKlaus
Addict
Addict
Posts: 1143
Joined: Sat Apr 10, 2004 1:20 pm
Location: Germany

Post by ABBKlaus »

a Macro seems to work, but i can´t get the imported functions to work.

You can test it by compiling with :

Code: Select all

PBCompiler.exe "source.pb" /RESIDENT resfile
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Post by ts-soft »

Imports works in a resident. Is the same as Prototype, the worked also
Only the Global Newlist is false.
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
ABBKlaus
Addict
Addict
Posts: 1143
Joined: Sat Apr 10, 2004 1:20 pm
Location: Germany

Post by ABBKlaus »

I do not see any size change with/without the imported functions.

So here is my list of what can contain a resident file :

- Constant
- Interface
- Structure
- Macro (see History of PureBasic help file : 8th May2006)
- Prototype (see History of PureBasic help file : 8th May2006)
Post Reply