Coder Social home page Coder Social logo

Code Errors (two) about viewtouch HOT 5 CLOSED

viewtouch avatar viewtouch commented on May 26, 2024
Code Errors (two)

from viewtouch.

Comments (5)

GeneMosher avatar GeneMosher commented on May 26, 2024 1

Thanks for the prompt code repair, NeroBurner ! I made a clean start of the /usr/viewtouch/dat directory and was able to determine that the first of the two Code Errors I made mention of here seems to be a file corruption issue. I intend to issue a new microSD image soon to rectify this problem.

from viewtouch.

NeroBurner avatar NeroBurner commented on May 26, 2024

Can't reproduce segfault 1


Segfault 2 is because Page 13 has no last label entry and my Str class doesn't like nullptr as argument to Set(const char*). What is the expected behavior on this page for the last form? I would either set the label to an empty string, then the input field is visible, but has no label on the left (see screenshot below). Or I could disable the form in this case and there would be no last entry visible

20210511_viewtouch_page13

The line with the segfault:

f->label.Set(PhraseData[idx].text);

f->label.Set(PhraseData[idx].text);

PhraseData[idx].text is a nullptr

from viewtouch.

NeroBurner avatar NeroBurner commented on May 26, 2024

I did some more digging for the second segfault: I recommend to update the PhraseData for this page 13 by removing the following line:

{12, FamilyName[31]},

The FamilyName[31] entry is a reference to NULL, (last entry of the following block):

viewtouch/main/labels.cc

Lines 297 to 307 in 4404676

const genericChar* FamilyName[] = {
"A La Carte", "Appetizer", "Breakfast Entree",
"Burger", "Lunch Entree", "Light Dinner",
"Dinner Entree", "Soup", "Child Menu",
"Dessert", "Salad", "Sandwich", "Seafood",
"Side Order", "Pizza", "Specialty", "Specialty Entree",
"Banquet", "Bakery",
"Beverage", "Beer", "Bottled Beer",
"Wine", "Bottled Wine", "Alcohol", "Cocktail",
"Malt Beverage", "Modifier", "Reorder",
"Merchandise", "Room", NULL};

from viewtouch.

NeroBurner avatar NeroBurner commented on May 26, 2024

Page 13 of 16 with labels.cc updated

image

from viewtouch.

NeroBurner avatar NeroBurner commented on May 26, 2024

reopen for the first segfault in "Receipts Balance" not yet fixed

from viewtouch.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.