View Single Post
Posts: 3,328 | Thanked: 4,476 times | Joined on May 2011 @ Poland
#2
I uploaded version 3.0.3-maemo1. This installs cleanly but there's a runtime error:
Code:
invoker: error: Failed to initiate connect on the socket.
invoker: warning: Connection with launcher process is broken
invoker: error: Start application ... as a binary executable without launcher
The first error is caused by this code:
Code:
// Inits a socket connection for the given application type
static int invoker_init(enum APP_TYPE app_type)
{
    int fd;
    struct sockaddr_un sun;

    fd = socket(PF_UNIX, SOCK_STREAM, 0);
    if (fd < 0)
    {
        error("Failed to open invoker socket.\n");
        return -1;
    }

    sun.sun_family = AF_UNIX;  //AF_FILE;

    const int maxSize = sizeof(sun.sun_path) - 1;
    if(app_type == M_APP)
    {
        strncpy(sun.sun_path, INVOKER_M_SOCK, maxSize);
    }
    else if (app_type == QT_APP)
    {
        strncpy(sun.sun_path, INVOKER_QT_SOCK, maxSize);
    }
    else if (app_type == QDECL_APP)
    {
      strncpy(sun.sun_path, INVOKER_QDECL_SOCK, maxSize);
    }
    else if (app_type == EXEC_APP)
    {
      strncpy(sun.sun_path, INVOKER_EXEC_SOCK, maxSize);
    }
    else
    {
        die(1, "Unknown type of application: %d\n", app_type);
    }

    sun.sun_path[maxSize] = '\0';

    if (connect(fd, (struct sockaddr *)&sun, sizeof(sun)) < 0)
    {
        error("Failed to initiate connect on the socket.\n");
        return -1;
    }

    return fd;
}
What may be wrong with it?
__________________
If you want to support my work, you can donate by PayPal or Flattr

Projects no longer actively developed: here

Last edited by marmistrz; 2013-09-30 at 18:33.
 

The Following 2 Users Say Thank You to marmistrz For This Useful Post: